var vanityTable = 
 {
     jamesandmaria: "http://seastararts.smugmug.com/gallery/6046109_5r6rV",
     traddproposes: "http://seastararts.smugmug.com/gallery/6244702_gCSp6",
     weddinginfo: "http://seastararts.smugmug.com/gallery/6352770_QhbbY" 
     
 };


function IsHomePage()
 {
    return(YD.hasClass(document.body, 'homepage'));
 }
 
 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
         }
     }
 }


function ContactFormValidate()
{
	if (document.ContactForm.customername.value == "")
	{
		alert("Your Name is required");
		document.ContactForm.customername.focus();
		return false;

	}
      if (document.ContactForm.customeremail.value == "")
	{
		alert("Your E-Mail Address is required");
		document.ContactForm.customeremail.focus();
		return false;
	}
	

}
