<!--
function validEmail(email) {
   invalidChars = " /:,;"
   
   if (email == "") {
      return (false);
   }
   for (i=0; i<invalidChars.length; i++) {
      badChar = invalidChars.charAt(i)
      if (email.indexOf(badChar, 0) > -1) {
         return (false);
      }
   }
   atPos = email.indexOf("@", 1)
   if (atPos == -1) {
      return (false);
   }
   if (email.indexOf("@", atPos+1) > -1) {
      return (false);
   }
   periodPos = email.indexOf(".", atPos)
   if (periodPos == -1) {
      return (false);
   }
   if(periodPos+3 > email.length) {
      return (false);
   }
   return (true);
}


function Validate()
{
	if (document.frmAdg.strName.value=="")
	{
		alert("please fill your name");
		document.frmAdg.strName.focus();
		return (false);
	}
	if (document.frmAdg.strCompany.value=="")
	{
		alert("please fill out company name");
		document.frmAdg.strCompany.focus();
		return (false);
	}

	if (document.frmAdg.strAddress.value=="")
	{
		alert("please enter your address");
		document.frmAdg.strAddress.focus();
		return (false);
	}
	
	
		if (document.frmAdg.strPhone.value=="")
	{
		alert("please enter your phone number");
		document.frmAdg.strPhone.focus();
		return (false);
	}
			
	if (document.frmAdg.strPhone.value != "")	
		{
      inputStr = "" + (document.frmAdg.strPhone.value)
			var threeChar = inputStr;
   			if(threeChar < 999999999)
						{
							alert("you must enter and area code and a seven digit number");
							document.frmAdg.strPhone.focus();
							return (false);
						}
		 }
		 
	if (document.frmAdg.strEmail.value=="")
	{
		alert("please enter your Email address");
		document.frmAdg.strEmail.focus();
		return (false);
	}
	
    if (!validEmail(document.frmAdg.strEmail.value))
	{
		alert("please enter a valid email");
		document.frmAdg.strEmail.focus();
		return (false);
	}

}
//-->