// this Script validates e-mail. subject, and message the form
// contact.htm
// contact2.asp
		

function validator(theForm) {
if (theForm.user_email.value == "")
{
alert("You must enter an e-Mail address!");
theForm.user_email.focus();
return (false);
}
var okEmail = theForm.user_email.value.match(/\b(^(\S+@).+((\.com)|(\.net)|(\.edu)|(\.mil)|(\.gov)|(\.org)|(\..{2,2}))$)\b/gi);
if (okEmail){
ok = true;
} else {
alert('Please enter a valid e-Mail address.');
theForm.user_email.focus();
theForm.user_email.select();
ok = false;
return false;
} 
if (theForm.user_subject.value == "")
{
alert("Please enter a Subject for your e-Mail!");
theForm.user_subject.focus();
return (false);
}
if (theForm.user_message.value == "")
{
alert("Please enter a Message!");
theForm.user_message.focus();
return (false);
}
return true;
}


//
