<!--
// JavaScript Document


	function welcome()
	{
	alert("noise")
	}
	
	function checkFirstname (strng) {
		 var error = "";
		 if (strng == "") {
		error = "You didn't enter a first name.\n";
	 	}
	 	return error;
	}
	
	function checkLastname (strng) {
		 var error = "";
		 if (strng == "") {
		error = "You didn't enter a last name.\n";
	 	}
	 	return error;
	}
	
	function checkEmail(strng) {
		var error = "";
		var emailFilter=/^.+@.+\..{2,3,4,6}$/;
		if (!(emailFilter.test(strng))) { 
			   error = "Please enter a valid email address.\n";
		}
		var illegalChars= /[\(\)\<\>\,\;\:\\\/\"\[\]]/
		if (strng.match(illegalChars)) {
		   error = "The email address contains illegal characters.\n";
		}
		return error;
	}
	
	
		
	function checkWholeForm(theForm) {
    var why = "";
    why += checkFirstname(theForm.firstname.value);
	why += checkLastname(theForm.lastname.value);
    why += checkEmail(theForm.email.value);
    if (why != "") {
       alert(why);
       return false;
	}
	else {
	return true;
	} 
	
	
	-->
