<!--Hide
function validEmail(email) {       				 //VALIDATION OF FORM
	invalidChars = " /:,;"

	if (email == "") {							// Must be filled in
		return false
	}
	for (i=0; i<invalidChars.length; i++) {		// Check to see if it contains illegal characters
		badChar = invalidChars.charAt(i)
		if (email.indexOf(badChar,0)> -1) {
			return false
		}
	}
	atPos = email.indexOf("@",1)				// There must be one "@" symbol
	if (atPos == -1) {
		return false
	}
	if (email.indexOf("@",atPos+1) != -1) {		// And only one "@" symbol
		return false
	}
	periodPos = email.indexOf(".",atPos)
	if (periodPos == -1) {						// And at least one "." after the "@"
		return false
	}
	if (periodPos+3> email.length)	{			// Must be at least 2 characters after the "."
		return false
	}
	

return true;	

}


function checkform(form){
whatState = form.State.selectedIndex;
whatStartDay = form.Arrival_Day.selectedIndex;
whatStartMonth = form.Arrival_Month.selectedIndex;
whatStartYear = form.Arrival_Year.selectedIndex;
whatEndDay = form.Departure_Day.selectedIndex;
whatEndMonth = form.Departure_Month.selectedIndex;
whatEndYear = form.Departure_Year.selectedIndex;
whatLocation = form.Location.selectedIndex;
whatType = form.Type.selectedIndex;
whatSend = form.Sendinfo.selectedIndex;
 
 
     if (form.Name.value == "") {
            alert("Please enter your Name.  Thank you.");
            form.Name.focus();
            return false;
            }
            
     if (form.Name.value.length < 2)  {
           alert("Please enter at least 2 characters in the \"Name\" field.");
           form.Name.focus();
           return (false);
           }
           
     if (form.Name.value.length > 30) {
          alert("Please enter at most 30 characters in the \"Name\" field.");
          form.Name.focus();
          return (false);
          }      
            
     if (form.Address1.value == "") {
          alert("Please enter your Street or PO Box Address.  Thank you.");
          form.Address1.focus();
          return false;
          }
            
     if (form.Address1.value.length < 5)  {
           alert("Please enter at least 5 characters in the \"Address1\" field.");
           form.Address1.focus();
           return (false);
           }

     if (form.Address1.value.length > 20)  {
          alert("Please enter at most 20 characters in the \"Address1\" field.");
          form.Address1.focus();
          return (false);
          }       
            
     if (form.City.value == "") {
            alert("Please enter your City.  Thank you.");
            form.City.focus();
            return false;
            }
            
     if (form.City.value.length < 3)  {
           alert("Please enter at least 3 characters in the \"City\" field.");
           form.City.focus();
           return (false);
           }

     if (form.City.value.length > 25)  {
           alert("Please enter at most 25 characters in the \"City\" field.");
           form.City.focus();
           return (false);
           }       
         
          
     if (form.State.options[whatState].value == "") {
             alert("Please select your state or province. Thank you.");
             form.State.focus();
             return false;
             } 
             
     if (form.Zip.value == "")  {
             alert("Please enter your Zip or Postal Code.");
             form.Zip.focus();
             return (false);
             }
     
     if (form.Zip.value.length < 5)  {
            alert("Please enter at least 5 characters in the \"Zip\" field.");
            form.Zip.focus();
            return (false);
            }
     
     if (form.Zip.value.length > 13)  {
           alert("Please enter at most 13 characters in the \"Zip\" field.");
           form.Zip.focus();
           return (false);
           }            
   
      if (form.Phone.value == "") {
            alert("Please enter your phone number so that we may contact you.  Thank you.");
            form.Phone.focus();
            return false;
            }       
        
            
      if (form.Arrival_Day.options[whatStartDay].value == "") {
             alert("Please enter your starting date of the rental. Thank you.");
             form.Arrival_Day.focus();
             return false;
             }
             
     if (form.Arrival_Month.options[whatStartMonth].value == "") {
             alert("Please enter your starting month of the rental. Thank you.");
             form.Arrival_Month.focus();
             return false;
             }
             
     if (form.Arrival_Year.options[whatStartYear].value == "") {
             alert("Please enter your starting year of the rental. Thank you.");
             form.Arrival_Year.focus();
             return false;
             }
             
      if (form.Departure_Day.options[whatEndDay].value == "") {
             alert("Please enter your ending date of the rental. Thank you.");
             form.Departure_Day.focus();
             return false;
             }
             
     if (form.Departure_Month.options[whatEndMonth].value == "") {
             alert("Please enter your ending month of the rental. Thank you.");
             form.Departure_Month.focus();
             return false;
             }
             
     if (form.Departure_Year.options[whatEndYear].value == "") {
             alert("Please enter your ending year of the rental. Thank you.");
             form.Departure_Year.focus();
             return false;
             }      
            
     if (form.Location.options[whatLocation].value == "") {
             alert("Please select the preferred \"Preferred Location\" of the rental. Thank you.");
             form.Location.focus();
             return false;
             }
             
     if (form.People.value == "") {
             alert("Please enter how many people do you need to accommodate. Thank you.");
             form.People.focus();
             return false;
             } 
             
     if (form.Type.options[whatType].value == "") {
             alert("Please select the \"Preferred Property Type\" that you are interested in. Thank you.");
             form.Type.focus();
             return false;
             }
             
     if (form.Sendinfo.options[whatSend].value == "") {
             alert("Please select how you would like us to send your information. Thank you.");
             form.Sendinfo.focus();
             return false;
             }
             
     if ((form.Sendinfo.options[whatSend].value == "Fax") && (form.Fax.value == "")) {
             alert("Please provide a fax number so we may Fax you the information.  Thank you.");
             form.Fax.focus();
             return false;
             }                        
            
      else if (!validEmail(form.email.value)) {
	      alert("Please enter your valid e-mail address.  Thank you.");
	      form.email.focus();
	      return false;
	  		
              }            
     	    
	
	var customer = document.ramsey_contact.Name.value;
	
	alert("Thank you, " + customer + ", for your Inquiry.  We will contact you as soon as possible about the information that you requested.")
       
  }   
  
//End Hide-->


