rightClickWarning = "All photos are © Nathan Leach-Proffer - Speed-Photos.net. All rights reserved. Unauthorized use is prohibited.  Please consider ordering prints or contacting me."

var Ll = new Array();
Ll[0] = "http://speed-photos.smugmug.com/photos/277827254_i2Y2B-L.jpg";
Ll[1] = "http://speed-photos.smugmug.com/photos/292625295_WTL4v-L.jpg";
Ll[2] = "http://speed-photos.smugmug.com/photos/277827261_8fyfM-L.jpg";
Ll[3] = "http://speed-photos.smugmug.com/photos/292625301_JY67V-L.jpg";
Ll[4] = "http://static.flickr.com/9/69950609_907cddc40c_o.jpg";

var P = new Array();
P[0] = "http://static.flickr.com/9/69950609_907cddc40c_o.jpg";
P[1] = "http://speed-photos.smugmug.com/photos/277827261_8fyfM-L.jpg";

var Lr = new Array();
Lr[0] = "http://speed-photos.smugmug.com/photos/277827261_8fyfM-L.jpg";
Lr[1] = "http://static.flickr.com/9/69950609_907cddc40c_o.jpg";
Lr[2] = "http://speed-photos.smugmug.com/photos/277827254_i2Y2B-L.jpg";
function choosePhoto(parray)
{
    inx = Math.floor(Math.random()*parray.length);
    img = parray[inx];
    document.write('<img border="2" src="' + img + '"/>');
}
  
function norobotmail(aUser, aDomain) { 
       document.location = "mailto:" + aUser + "@" + aDomain;
    }


SM.PhotoBar.config.position = 'bottom';


function ModifyText ()
{
  if (YD.hasClass(document.body, "gallery_5881767"))
  {
    var objElement = YD.get("comment")
    if (objElement != null)
    {
      var str = new String(objElement.innerHTML);
      str = str.replace(/\gallery/gi, 'guestbook');
      objElement.innerHTML = str;
    }
  }
}

YE.onAvailable("comment", ModifyText);

var vanityTable = 
 {
     photoshoots : "http://www.speed-photos.net/Automotive%20Photography/177009",
     naias : "http://www.speed-photos.net/Automotive%20Photography/654493",
     monterey2007: "http://www.speed-photos.net/Automotive%20Photography/369202",
     monterey2006: "http://www.speed-photos.net/Automotive%20Photography/221023"
 };

function CheckRedirects()
 {
     if (YD.hasClass(document.body, 'homepage'))    // only run this code on the home page
     {
         // get the path from the current URL, 
         // convert it to lowercase and remove the leading slash
         var path = window.location.pathname.toLowerCase().substr(1);
         
         var newURL = vanityTable[path];        // look it up in our table
         
         // if we found it in the table && newURL is different than where we are
         if (newURL && (newURL != window.location))
         {
             window.location.replace(newURL);        // go to the new URL
         }
     }
 }