<!-- chkcontact.js - Last Modified: 10/11/04 Madhavan Consulting, http://www.madhavan.biz -->

<!-- Web Wiz Email Forms is written by Bruce Corkhill © 2001-2002 -->
<!--
function CheckForm () { 
	var errorMsg = "";

	if (document.frmEnquiry.firstName.value == ""){
		errorMsg += "\n\tFirst Name \t- Enter your First Name";	
	}
	
	if (document.frmEnquiry.lastName.value == ""){
		errorMsg += "\n\tLast Name \t- Enter your Last Name";
	}
	 	
	if ((document.frmEnquiry.email.value == "") || (document.frmEnquiry.email.value.length > 0 && (document.frmEnquiry.email.value.indexOf("@",0) == - 1 || document.frmEnquiry.email.value.indexOf(".",0) == - 1))) { 
		errorMsg += "\n\tE-mail Address \t- Enter your valid e-mail address";
	}

	if (document.frmEnquiry.enquiry.value == "") { 
 		errorMsg += "\n\tMessage \t\t- Enter your message";
	}
		
	if (errorMsg != ""){
		msg = "______________________________________________________________\n\n";
		msg += "Your message has not been sent because there are problems with the form.\n";
		msg += "Please correct the problems and re-submit the form.\n";
		msg += "______________________________________________________________\n\n";
		msg += "The following field(s) need to be corrected: \n";
		
		errorMsg += alert(msg + errorMsg + "\n\n");
		return false;
	}
	
	return true;
}
// -->

