// Vanity
var vanityTable = 
 {
     products: "http://www.lens-bh.com/System/Services/7374315_ogGtr",
     mohamedghuloom : "http://lens-bh.com/LENSORS/Mohamed-Ghuloom-LENSTA/7109599_A8rrL",
     learn: "http://lens-bh.com/System/Learn-Photography/8673897_NFwjY",
     free: "http://lens-bh.com/share/ad6xA4WXMqXtU",
     staff: "http://www.lens-bh.com/System/LENSORS/9600490_NBR6p",
     faq: "http://www.lens-bh.com/System/faq/11131577_B7D7L",
     testimonials: "http://www.lens-bh.com/System/Testimonials/6819351_4TqJE"
}
 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
         }
     }
 }







YE.addListener(document, "keyup", pageNav);

function pageNav(e) {
  if (!e) 
    e = window.event;

  if (!YD.hasClass(document.body, "galleryPage"))
    return;

  switch (e.keyCode) {
    case 37:
      chk = "&lt;";
      break;

    case 39:
      chk = "&gt;";
      break;

    default:
      return;
  }
  
  oList = YD.getElementsByClassName("nav", "a", YD.get("albumNav_top"));
  for (var i=0; i < oList.length ; i++) {
    if (oList[i].innerHTML == chk) {
      window.location = oList[i].href;
      break;
    }
  }
}