// JavaScript Document

function set(){
	
	//name validation
if (document.form1.firstname.value == "")
	{
		alert("Please Enter Your First Name");
		document.form1.firstname.focus();
		return false ;
	}
if (document.form1.lastname.value == "")
	{
		alert("Please Enter Your Last Name");
		document.form1.lastname.focus();
		return false ;
	}
	//end of name validation
	
	//zip code validation	
if (isNaN(document.form1.zip.value))
	{
		alert("Invalid Postal Code/Zip");
		document.form1.zip.focus();
		document.form1.zip.select();
		return false;
	}
	//end of zip code validation
	
	//email validation
var email = document.form1.email.value;

	if(email=="")
	{
		alert("Please Enter Your Email Id") ;
		document.form1.emailemail.focus();
		return false;
	}
	
	if (!email.match(/^[\w\.\-]+@([\w\-]+\.)+[a-zA-Z]+$/))
	{
		alert("Please enter a valid e-mail address.");
		document.form1.email.focus();
		document.form1.email.select();
		return false;
	}
	//end of email validation	

	//phone validation
if (document.form1.phone.value == "")
	{
		alert("Please Enter Your Telephone No");
		document.form1.phone.select();
		return false ;
	}
	if (isNaN(document.form1.phone.value))
	{
		alert("Invalid Phone Number");
		document.form1.phone.select();
		return false;
	}
	//end of phone validation
	
	return true ;
}