<!--
function validateRegistrationPage()
{
	
	//first name validation --mahir
  if(document.Registration.fname.value.length < 1)
  		{
		submitFlag = false;
		alert("Please enter your first name!");
		document.Registration.fname.focus();
	  } 
	  //last name validation
	  else if (document.Registration.lname.value.length < 1)
		{
			submitFlag = false;
			alert("Please enter your last name!");
			document.Registration.lname.focus();
	  	} 
		//the last 4 digits of SSN validation
		else if (document.Registration.ssn4.value.length < 1)
		{
			submitFlag = false;
			alert("Please enter the last 4 digits of your SSN!");
			document.Registration.ssn4.focus();
	  	} 
		//make sure the SSN length is 4 
		else if(document.Registration.ssn4.value.length != 4)
	  {
		  submitFlag = false;
		  alert("You must enter the last 4 digits of your Social Security Number.");
		  document.Registration.ssn4.focus();
	  }
	  //password validation
	 // else if (document.Registration.password1.value.length < 1)
		//{
			//submitFlag = false;
			//alert("Please enter your password");
			//document.Registration.password1.focus();
	  	//} 
	  //make sure that the password length is between 6 and 8 char.
	else if(document.Registration.password1.value.length < 6)
	  {
		  submitFlag = false;
		  alert("Your password must be between 6 and 15 characters in length.");
		  document.Registration.password1.focus();
	  }
	  else if(document.Registration.password1.value.length > 15)
	  {
		  submitFlag = false;
		  alert("Your password must be between 6 and 15 characters in length.");
		  document.Registration.password1.focus();
	  }
		//passowrd confirmation
		else if (document.Registration.password2.value.length < 1)
		{
			submitFlag = false;
			alert("Please re-enter your password!");
			document.Registration.password2.focus();
	  	} 
		// make sure the passwords are match
		else if(document.Registration.password1.value != document.Registration.password2.value)
	  {
		  submitFlag = false;
		  alert("Your passwords do not match!");
		  document.Registration.password2.focus();
	  }
	  //birth date validation
		else if (document.Registration.birth.value.length < 10)
		{
			submitFlag = false;
			alert("Please enter your birth date in mm/dd/yyyy format!");
			document.Registration.birth.focus();
	  	} 
		//street address validation
		else if (document.Registration.street1.value.length < 1)
		{
			submitFlag = false;
			alert("Please enter your street address!");
			document.Registration.street1.focus();
	  	} 
		//city validation
		else if (document.Registration.city.value.length < 1)
		{
			submitFlag = false;
			alert("Please enter city name!");
			document.Registration.city.focus();
	  	} 
		//state validation
		else if (document.Registration.state.value.length < 1)
		{
			submitFlag = false;
			alert("Please enter state (Abbrev.)!");
			document.Registration.state.focus();
	  	} 
		//zip code avalidation
		else if (document.Registration.zip.value.length < 1)
		{
			submitFlag = false;
			alert("Please enter zip code!");
			document.Registration.zip.focus();
	  	} 
		//email address validation
		else if (document.Registration.email.value.length < 1)
		{
			submitFlag = false;
			alert("Please enter valid email address!");
			document.Registration.email.focus();
	  	} 
		//re-type email address
		else if (document.Registration.email1.value.length < 1)
		{
			submitFlag = false;
			alert("Please re-enter valid email address!");
			document.Registration.email1.focus();
	  	} 
		//make sure the email addesses are match
		else if(document.Registration.email.value != document.Registration.email1.value)
	  {
		  submitFlag = false;
		  alert("Your emails do not match!");
		  document.Registration.email1.focus();
	  }
		//day phone number validation
		else if (document.Registration.dphone.value.length < 1)
		{
			submitFlag = false;
			alert("Please enter your day phone number!");
			document.Registration.dphone.focus();
	  	} 
	  else {
	  submitFlag = true;
	  }
	  return submitFlag;
}


function validateProfilePage()
{
	
	
	if((document.Profile.fname.value.length < 1) || 
	   (document.Profile.lname.value.length < 1) ||
	   (document.Profile.ssn4.value.length < 1) ||
	   (document.Profile.street1.value.length < 1) ||
	   (document.Profile.city.value.length < 1) ||
	   (document.Profile.state.value.length < 1) ||
	   (document.Profile.zip.value.length < 1) ||
	   (document.Profile.dphone.value.length < 1) ||
	   (document.Profile.nphone.value.length < 1))
	  {
		submitFlag = false;
		alert("All required fields are not met!\nPlease doube check your fields and try again.");
	  } 
	  
 else if(document.Profile.ssn4.value.length != 4)
	  {
		  submitFlag = false;
		  alert("You must enter the last 4 digits if your Social Security Number.");
	  }
	
	  else {
	  submitFlag = true;
	  }
	  return submitFlag;
}

function validatePasswordPage()
{
	
	
	if((document.Password.oldpass.value.length < 1) || 
	   (document.Password.newpass1.value.length < 1) ||
	   (document.Password.newpass2.value.length < 1))
	  {
		submitFlag = false;
		alert("All required fields are not met!\nPlease double check your fields and try again.");
	  }
else if (document.Password.newpass1.value.length < 6 ||
		 document.Password.newpass1.value.length > 15)
	  {
	  	submitFlag = false;
	  	alert('The password length must be between 6 and 15 characters long.');
	  }
	  
 else if(document.Password.newpass1.value != document.Password.newpass2.value)
	  {
		  submitFlag = false;
		  alert("New passwords do not match!");
	  }
	
	  else {
	  submitFlag = true;
	  }
	  return submitFlag;
}
-->

