function Validate(theForm) {
   if (Trim(theForm.FirstName.value) == "")
  {
    alert("Please enter First Name.");
    theForm.FirstName.focus();
    return (false);
  }
  if (Trim(theForm.LastName.value) == "")
  {
    alert("Please enter Last Name.");
    theForm.LastName.focus();
    return (false);
  }
  if (Trim(theForm.LicensingState.value) == "")
  {
    alert("Please enter Licensing State.");
    theForm.LicensingState.focus();
    return (false);
  } 
  if (Trim(theForm.LicenseNumber.value) == "")
  {
    alert("Please enter License Number.");
    theForm.LicenseNumber.focus();
    return (false);
  } 
  if (Trim(theForm.Email.value) == "")
  {
    alert("Please enter your Email Address.");
    theForm.Email.focus();
    return (false);
  }
	var checkStr = theForm.Email.value;
	checkStr2 = checkStr.toLowerCase()
  if (checkStr2.indexOf('bellacollina.com')>1 ||
  	 checkStr2.indexOf('reunionresort.com')>1 ||
	 checkStr2.indexOf('tesoroclub.com')>1 ||
	 checkStr2.indexOf('cobblestonesc.com')>1 ||
	 checkStr2.indexOf('quailwest.com')>1 ||
	 checkStr2.indexOf('hammockbeach.com')>1 ||
	 checkStr2.indexOf('laurelmor.com')>1 ||
	 checkStr2.indexOf('ginncompany.com')>1 )
  {
	 alert("Ginn Company Email Addresses Will Not Be Accepted.");
   	 theForm.Email.focus();
   	 return (false);
  }
	
	var ch = checkStr.indexOf('@');

	if (ch==0 || ch==-1) {
		alert("Please enter a valid Email Address.");
		theForm.Email.focus();
		return (false);
	}
	var checkOK = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyzfSOZsozYÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõöøùúûüýþ0123456789-@.-_'";
	var checkStr = theForm.Email.value;
	var allValid = true;
	for (i = 0;  i < checkStr.length;  i++) {
		ch = checkStr.charAt(i);
		for (j = 0;  j < checkOK.length;  j++)
			if (ch == checkOK.charAt(j))
				break;
				if (j == checkOK.length) {
					allValid = false;
					break;
				}
	}
	if (!allValid) {
		alert("Please enter only letters, digits and \"@.-_'\" characters in the \"Email\" field.");
		theForm.Email.focus();
		return (false);
	}
	 if ((theForm.Email.value) != (theForm.VerifyEmail.value))
  {
    alert("Please Verify Email Address.");
    theForm.VerifyEmail.focus();
    return (false);
  }
  
   if (Trim(theForm.City.value) == "")
  {
    alert("Please enter your City.");
    theForm.City.focus();
    return (false);
  }
   if (Trim(theForm.State.value) == "")
  {
    alert("Please enter your State.");
    theForm.State.focus();
    return (false);
  }
  if (Trim(theForm.Zip.value) == "")
  {
    alert("Please enter your Zip.");
    theForm.Zip.focus();
    return (false);
  }
  
	//at least one phone number
	if ((Trim(theForm.Phone.value) == "")&& (Trim(theForm.CellPhone.value) == "")&&(Trim(theForm.HomePhone.value) == ""))
  {
    alert("Please enter at least one Phone Number.");
    theForm.Phone.focus();
    return (false);
  } 
	
	var checkOK = "0123456789()- ";
	var checkStr = theForm.Phone.value;
	var allValid = true;
	for (i = 0;  i < checkStr.length;  i++) {
		ch = checkStr.charAt(i);
		for (j = 0;  j < checkOK.length;  j++)
			if (ch == checkOK.charAt(j))
				break;
				if (j == checkOK.length) {
					allValid = false;
					break;
				}
	}
	if (!allValid) {
		alert("Please enter only digits for the Work Number.");
		theForm.Phone.focus();
		return (false);
	}
	
	var checkOK = "0123456789()- ";
	var checkStr = theForm.CellPhone.value;
	var allValid = true;
	for (i = 0;  i < checkStr.length;  i++) {
		ch = checkStr.charAt(i);
		for (j = 0;  j < checkOK.length;  j++)
			if (ch == checkOK.charAt(j))
				break;
				if (j == checkOK.length) {
					allValid = false;
					break;
				}
	}
	if (!allValid) {
		alert("Please enter only digits for the Cell Number.");
		theForm.CellPhone.focus();
		return (false);
	}
	
	var checkOK = "0123456789()- ";
	var checkStr = theForm.HomePhone.value;
	var allValid = true;
	for (i = 0;  i < checkStr.length;  i++) {
		ch = checkStr.charAt(i);
		for (j = 0;  j < checkOK.length;  j++)
			if (ch == checkOK.charAt(j))
				break;
				if (j == checkOK.length) {
					allValid = false;
					break;
				}
	}
	if (!allValid) {
		alert("Please enter only digits for the Home Phone Number.");
		theForm.HomePhone.focus();
		return (false);
	}
	
	/*var checkOK = "0123456789()- ";
	var checkStr = theForm.Zip.value;
	var allValid = true;
	for (i = 0;  i < checkStr.length;  i++) {
		ch = checkStr.charAt(i);
		for (j = 0;  j < checkOK.length;  j++)
			if (ch == checkOK.charAt(j))
				break;
				if (j == checkOK.length) {
					allValid = false;
					break;
				}
	}
	if (!allValid) {
		alert("Please enter only digits for the Zip Code.");
		theForm.Zip.focus();
		return (false);
	}*/
   
	//var checkOK = "0123456789";
	//var checkStr = theForm.NumPeople.value;
	//var allValid = true;
	//for (i = 0;  i < checkStr.length;  i++) {
		//ch = checkStr.charAt(i);
		//for (j = 0;  j < checkOK.length;  j++)
			//if (ch == checkOK.charAt(j))
				//break;
				//if (j == checkOK.length) {
					//allValid = false;
					//break;
				//}
	//}
	//if (!allValid) {
		//alert("Please enter only digit for the number of people.");
		//theForm.NumPeople.focus();
		//return (false);
	//}
		return (true);
}
