function hasPath(sPath)
{
re = new RegExp("\/" + sPath + "(\/|$)");
return re.test(window.location)
}

function IsHomePage()
 {
    return((YD.hasClass(document.body, 'homepage')) && (!(YD.hasClass(document.body, "galleries"))));
 }
 
 function CheckRedirects()
 {
     if (IsHomePage())    // only run this code on the home page
     {
         var newURL = "/gallery/8036059_rB4QG"        // look it up in our table
        
             window.location.replace(newURL);        // go to the new URL
     }
 }
