﻿// JavaScript Document
<!-- hide me

function validateContact_En(){
var testresults;
var strName = document.EnContact.sender_Fname.value;
var strLastName = document.EnContact.sender_Lname.value;
var strEmail = document.EnContact.sender_email.value;
var strsecuritycode = document.EnContact.securitycode.value;


var filter=/^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i;
//var dhfygiennum=/(^\d+$)|(^\d+\.\d+$)/;
var telnum=/[\d\D]+$/;
if( strName != "" && strLastName != "" && strEmail != "" && strsecuritycode != "" )
{
	testresults=true;
	
	if (!telnum.test(strsecuritycode))
	{
		alert("Security Code does not match!");
		testresults=false;
	}
	
	if (!filter.test(strEmail))
	{
		alert("Invalid Email Address. Please try again!");
		testresults=false;
	}	
}
else
{
	var strAlert = "Please fill infomation in the blank field";
	if(strName == "")
	{
		strAlert = strAlert + " - First Name";
	}
	
	if(strLastName == "")
	{
		strAlert = strAlert + " - Last Name";
	}
	
	
	if(strEmail == "")
	{
		strAlert = strAlert + " - Email Address";
	}

	
	if(strsecuritycode == "")
	{
		strAlert = strAlert + " - Security Code";
	}
	alert(strAlert);
	testresults=false;
}
return (testresults);
}




// show me-->