function submitCheck(customerForm) {
	
	//Regular expression definitions
	//http://www.regular-expressions.info/email.html
	var lettersOnly = /^[a-zA-Z -.]+$/;
	var numbersOnly =  /^[0-9 ()]+$/;
	
	//Check if name has been entered (REQUIRED FIELD)
	if (customerForm.cname.value == "") {
		alert("You must enter a name.")
		
	return false
	}
    
    //Check for letters only (and - or.) in name
    if(!customerForm.cname.value.match(lettersOnly)) {
		alert("'"+customerForm.cname.value+"' is not a valid name (must contain letters only).")
					
	return false
	}
	
	//Check for numbers (or parenthesis) only in phone number (only if there is content IN this field)
	if(!customerForm.phone.value.match(numbersOnly)&&customerForm.phone.value!="") {
		alert("'"+customerForm.phone.value+"' is not a valid phone number (The phone number field may only contain numbers.).")
					
	return false
	}
	
	//Check if email has been entered (REQUIRED FIELD)
	if (customerForm.email.value == "") {
		alert("You must enter a valid email Address.")
		
		return false
	}		
	
	//Check that @ symbol is included (at least 1 character from start)
    if(customerForm.email.value.indexOf("@")<1) {
		alert("'"+customerForm.email.value+"' is not a valid email address")
					
	return false
	}
	

	
}

/*
function securityCode(size) {
	
   var chars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890";
   var pass = "";
   var i
   var h
   

   for(i=0;i<size;i++)
   {
      h = Math.floor(Math.random() * 62);
      pass += chars.charAt(h);
   }

   return pass;
}
   */
   
