// JavaScript Document
function Validate(form) {
//alert('We are validating');

//alert('Checking Email');
//Email Validation, checks for invalid characters and if the field is empty
	if (! form.email.value.match(/^[\w\d!#$%&'*+-\/=?^`{|}~]+(\.[\w\d!#$%&'*-\/=?^`{|}~]+)*@[A-Za-z\d][-A-Z-a-z\d]*[A-Za-z\d]\.*[A-Za-z][-A-Z-a-z\d]*[A-Za-z]$/)) {
		alert('Please enter a valid email address');
		form.email.focus();
		form.email.style.backgroundColor = "#FFFF66";
        return false;
    } else {
		form.email.style.backgroundColor = "#FFFFFF";
	}

//If the email verifies to be valid we Submit by returning TRUE	

//alert('Checking Password');
//Password Validation	
    if (form.email.value != form.email2.value)
    {
        alert('The email address does not match');
   		form.email.style.backgroundColor = "#FFFF66";
		form.email.focus();
		return false;
    } else {
		form.email.style.backgroundColor = "#FFFFFF";
    }


return true;
}
