 
 var vanityTable = 
 {
 	rosefestival : "http://photos.brianwestbrook.net/gallery/1561977",
        portlandpride2006 : "http://photos.brianwestbrook.net/Portland%20Events/198290"
 };
 
 function IsHomePage()
 {
 	// test for the "homepage" class name in the <BODY> tag
 	var bodyTag = document.body;
 	if (bodyTag)
 	{
 		var classStr = bodyTag.className;
 		if (classStr && (classStr.indexOf("homepage") != -1))
 		{
 			return(true);
 		}
 	}
 	return(false);
 }
 
 function CheckRedirects()
 {
 	if (IsHomePage())	// 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
 		}
 	}
 }
 