// JavaScript Document

function checkEmail (strng) {
var error="";
  if (strng == "") {
     error = "You didn't enter an Email Address.\n";
  } else {
    var emailFilter=/^.+@.+\..{2,3}$/;
    if (!(emailFilter.test(strng))) {
       error = "Please enter a valid Email Address.\n";
    } else {
      //test email for illegal characters
      var illegalChars= /[\(\)\<\>\,\;\:\\\"\[\]]/
      if (strng.match(illegalChars)) {
         error = "The email address contains illegal characters.\n";
      }
    }
  }
return error;
}

// non-empty Name
function isEmptyName(strng) {
var error = "";
  if (strng.length == 0) {
     error = "Please fill in your Full Name.\n"
  }
return error;
}

 
