// non-empty textbox
function CheckisEmpty(strng,fldname) {
var error = "";
strngval=strng.value;
if (strngval.length == 0) {error = "The "+ fldname + " field has not been filled in.\n"}
return error;	  
}
// email
function checkEmail (strng,fldname) {
var error="";
strngval=strng.value;
var emailFilter=/^.+@.+\..{2,3}$/;
if (strngval == "") {error = "The "+ fldname + " field has not been filled in.\n";}
else if (!(emailFilter.test(strngval))) {error = "Please enter a valid Email Address in the "+ fldname + " field.\n";}
else {
//test email for illegal characters
var illegalChars= /[\(\)\<\>\,\;\:\\\"\[\]]/;
if (strngval.match(illegalChars)) {error = "The Email Address in the "+ fldname + " field contains illegal characters.\n";}
}
return error;    
}
function hide(id) {document.getElementById(id).style.visibility=("hidden");}

