﻿<!--
function validate_p1() {
  		//Position Desired
		if (document.sureform.pg1Position.value=="") {
			alert("Please Enter Position Desired !");
			document.sureform.pg1Position.focus();
			return false
		}
		
		//Last Name
		if (document.sureform.pg1LastName.value=="") {
			alert("Please Enter Your Last Name !");
			document.sureform.pg1LastName.focus();
			return false
		}
		
		//First Name
		if (document.sureform.pg1FirstName.value=="") {
			alert("Please Enter Your First Name !");
			document.sureform.pg1FirstName.focus();
			return false
		}		
		
		//Street Address  
		if (document.sureform.pg1Street.value=="") {
			alert("Please Enter Your Street Address !")
			document.sureform.pg1Street.focus();
			return false
		}
				
		//City
		if (document.sureform.pg1City.value=="") {
			alert("Please Enter Your City !");
			document.sureform.pg1City.focus();
			return false
		}
		
		//Zip Code- Check if numeric
		if (document.sureform.pg1Zip.value != "") {
			var strPg1Zip = document.sureform.pg1Zip.value;
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Zip.length && boolResult == true; i++) {
				strPg1Char = strPg1Zip.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Zip code error: valid characters are 0 through 9")
				document.sureform.pg1Zip.focus();
				return false
			}
			else if (strPg1Zip.length != 5) {
				alert("Zip code must be 5 digits")
				document.sureform.pg1Zip.focus();
				return false
			}
		}
		
		//Zip code is blank
		else {
			alert("Please Enter Your Zip Code !")
			document.sureform.pg1Zip.focus();
			return false
		}
				
		//SSN1
//		if (document.sureform.pg1SSN1.value != "") {
//			var tmpSSN1 = document.sureform.pg1SSN1.value;
//			var strPg1ValidChars = "0123456789";
//			var strPg1Char;
//			var boolResult = true;
//
//			for (i = 0; i < tmpSSN1.length && boolResult == true; i++) {
//				strPg1Char = tmpSSN1.charAt(i);
//				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
//					boolResult = false;
//			} // end for
//			
//			
//			if (boolResult == false) {
//				alert("SSN:  Please only enter numerics for SSN !")
//				document.sureform.pg1SSN1.focus();
//				return false
//
//			}
//			else if (tmpSSN1.length != 3) {
//				alert("SSN: Please enter first 3 digits of SSN")
//				document.sureform.pg1SSN1.focus();
//				return false
//			}
//		}
//
//		//SSN2
//		if (document.sureform.pg1SSN2.value != ""  || document.sureform.pg1SSN1.value != "") {
//			var tmpSSN2 = document.sureform.pg1SSN2.value;
//			var strPg1ValidChars = "0123456789";
//			var strPg1Char;
//			var boolResult = true;
//  
//			for (i = 0; i < tmpSSN2.length && boolResult == true; i++) {
//				strPg1Char = tmpSSN2.charAt(i);
//				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
//					boolResult = false;
//			} // end for
//			
//			if (boolResult == false) {
//				alert("SSN:  Please only enter numerics for SSN !");
//				document.sureform.pg1SSN2.focus();
//				return false
//			}
//			else if (tmpSSN2.length != 2) {
//				alert("SSN: Please enter middle 2 digits of SSN");
//				document.sureform.pg1SSN2.focus();
//				return false
//			}
//		}
		//SSN3
//		if (document.sureform.pg1SSN3.value != "" || document.sureform.pg1SSN1.value != "") {
//			var tmpSSN3 = document.sureform.pg1SSN3.value;
//			var strPg1ValidChars = "0123456789";
//			var strPg1Char;
//			var boolResult = true;
  
//			for (i = 0; i < tmpSSN3.length && boolResult == true; i++) {
//				strPg1Char = tmpSSN3.charAt(i);
//				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
//					boolResult = false;
//			} // end for
			
//			if (boolResult == false) {
//				alert("SSN:  Please only enter numerics for SSN !");
//				document.sureform.pg1SSN3.focus();
//				return false
//			}
//			else if (tmpSSN3.length != 4) {
//				alert("SSN: Please enter last 4 digits of SSN");
//				document.sureform.pg1SSN3.focus();
//				return false
//			}
//		}

		//Primary Phone- check that area code is numeric
		if (document.sureform.pg1PrimPhone1.value != "") {
			var strPg1Phone = document.sureform.pg1PrimPhone1.value;
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;
  
			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Primary Phone Error:  Please only enter numerics for Area Code !");
				document.sureform.pg1PrimPhone1.focus();
				return false
			}
			else if (strPg1Phone.length != 3) {
				alert("Primary Phone Error: Please enter 3 digit Area Code");
				document.sureform.pg1PrimPhone1.focus();
				return false
			}
		}
		
		//Primary Phone- area code is blank
		else {
			alert("Primary Phone Error:  Please enter Area Code !");
			document.sureform.pg1PrimPhone1.focus();
			return false
		}

		//Primary Phone- check that next 3 digits are numeric
		if (document.sureform.pg1PrimPhone2.value != "") {
			var strPg1Phone = document.sureform.pg1PrimPhone2.value;
			
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Primary Phone Error:  Please only enter numerics for first 3 digits of phone number");
				document.sureform.pg1PrimPhone2.focus();
				return false
			}
			
			else if (strPg1Phone.length != 3) {
				alert("Primary Phone Error: Please enter first 3 digits of phone number");
				document.sureform.pg1PrimPhone2.focus();
				return false
			}
		}
		
		//Primary Phone- next 3 digits are blank
		else {
			alert("Primary Phone Error:  Please enter first 3 digits of phone number");
			document.sureform.pg1PrimPhone2.focus();
			return false
		}

		//Primary Phone- check that last 4 digits are numeric
		if (document.sureform.pg1PrimPhone3.value != "") {
			var strPg1Phone = document.sureform.pg1PrimPhone3.value;
			
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Primary Phone Error:  Please only enter numerics for last 4 digits of phone number");
				document.sureform.pg1PrimPhone3.focus();
				return false
			}
			
			else if (strPg1Phone.length != 4) {
				alert("Primary Phone Error: Please enter last 4 digits of phone number");
				document.sureform.pg1PrimPhone3.focus();
				return false
			}
		}
		
		//Primary Phone- last 4 digits are blank
		else {
			alert("Primary Phone Error:  Please enter last 4 digits of phone number");
			document.sureform.pg1PrimPhone3.focus();
			return false
		}
  		
		//Secondary Phone- check that area code is numeric
		if (document.sureform.pg1ScndPhone1.value != "") {
			var strPg1Phone = document.sureform.pg1ScndPhone1.value;
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;
  
			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Secondary Phone Error:  Please only enter numerics for Area Code !");
				document.sureform.pg1ScndPhone1.focus();
				return false
			}
			else if (strPg1Phone.length != 3) {
				alert("Secondary Phone Error: Please enter 3 digit Area Code");
				document.sureform.pg1ScndPhone1.focus();
				return false
			}
		}
		
		//Secondary Phone- check that next 3 digits are numeric
		if (document.sureform.pg1ScndPhone1.value != "") {
			var strPg1Phone = document.sureform.pg1ScndPhone2.value;
			
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Secondary Phone Error:  Please only enter numerics for first 3 digits of phone number");
				document.sureform.pg1ScndPhone2.focus();
				return false
			}
			
			else if (strPg1Phone.length != 3) {
				alert("Secondary Phone Error: Please enter first 3 digits of phone number");
				document.sureform.pg1ScndPhone2.focus();
				return false
			}
		}
		
		//Secondary Phone- next 3 digits are blank
		else if (document.sureform.pg1ScndPhone1.value != "" && document.sureform.pg1ScndPhone2.value == "") {
			alert("Secondary Phone Error:  Please enter first 3 digits of phone number");
			document.sureform.pg1ScndPhone2.focus();
			return false
		}

		//Secondary Phone- check that last 4 digits are numeric
		if (document.sureform.pg1ScndPhone1.value != "") {
			var strPg1Phone = document.sureform.pg1ScndPhone3.value;
			
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Secondary Phone Error:  Please only enter numerics for last 4 digits of phone number");
				document.sureform.pg1ScndPhone3.focus();
				return false
			}
			
			else if (strPg1Phone.length != 4) {
				alert("Secondary Phone Error: Please enter last 4 digits of phone number");
				document.sureform.pg1ScndPhone3.focus();
				return false
			}
		}
		
		//Secondary Phone- last 4 digits are blank
		else if (document.sureform.pg1ScndPhone1.value != "" && document.sureform.pg1ScndPhone3.value == "")  {
			alert("Secondary Phone Error:  Please enter last 4 digits of phone number");
			document.sureform.pg1ScndPhone3.focus();
			return false
		}
 		
		//Email Address
		if (document.sureform.pg1Email.value != "") {
			var str=document.sureform.pg1Email.value;
			var filter=/^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i
			if (!filter.test(str)) {		
				alert("Please input a valid email address!")
				document.sureform.pg1Email.focus();
				return false	
			}
		}

		//How did you hear desc only if ( is in the selection- you must enter the description
		var myindex=document.sureform.pg1HowHear.selectedIndex;
		if ((myindex == 0 || myindex == 3 || myindex == 4 || myindex == 5) && document.sureform.pg1HowHearDesc.value == ""){
			alert("Please enter How did you hear description");
			document.sureform.pg1HowHearDesc.focus();
			return false
		} 	
		
		//If previous employee provide dates
		var myindex=document.sureform.pg1Employed.selectedIndex;
		if (myindex == 0) {
			var myindex2 = document.sureform.pg1PrevEmplMonth.selectedIndex;
			var myindex3 = document.sureform.pg1PrevEmplYear.selectedIndex;
			if (myindex2 == 0) {
				alert("Please enter Previous Employment Month!");
				document.sureform.pg1PrevEmplMonth.focus();
				return false
			}
			if (myindex3 == 0) {
				alert("Please enter Previous Employement Year!");
				document.sureform.pg1PrevEmplYear.focus();
				return false
			}
		}		

		//Type of employment desired- make sure that at least one of the checkboxes are checked
		var boolCheck = false;
		if (document.sureform.pg1FullTime.checked == true)
			boolCheck = true;
	    else if (document.sureform.pg1Internship.checked == true)
			boolCheck = true;
		else if (document.sureform.pg1PartTime.checked == true)
			boolCheck = true;
	    else if (document.sureform.pg1Seasonal.checked == true)
			boolCheck = true;
		else
			boolCheck = false;
			
	  	if (boolCheck == false) {
	  		alert("Please select at least one Type of employment desired");
	  		document.sureform.pg1FullTime.focus();
			return false		
		}  
 		
		//If you have restricitons, restrictionDesc must be filled in 
		var myindex=document.sureform.pg1Restrictions.selectedIndex;
		if (myindex == 0) {
			if (document.sureform.pg1RestrictionDesc.value.length == 0) {
				alert("Please enter your Restriction Description!");
				document.sureform.pg1RestrictionDesc.focus();
				return false
			}
		}
		
		//Limit restriction description to 1000 characters
		if (document.sureform.pg1RestrictionDesc.value.length > 255) {
				alert("Please limit your restriction description to 255 characters!");
				document.sureform.pg1RestrictionDesc.focus();
				return false
		}
 
		//Emplyment History- Employer Name
		if (document.sureform.pg1Employer.value == "") {	
			alert("Please Enter Employer Name under Employment History !");
			document.sureform.pg1Employer.focus();
			return false		
		} 
		
		//Emplyment History- Employer Street Address 
		if (document.sureform.pg1EmployerStreet.value == "") {	
			alert("Please Enter Employer Street Address under Employment History !");
			document.sureform.pg1EmployerStreet.focus();
			return false		
		} 

		//Emplyment History- Employer City
		if (document.sureform.pg1EmployerCity.value == "") {	
			alert("Please Enter Employer City under Employment History !");
			document.sureform.pg1EmployerCity.focus();
			return false		
		} 
		
		//Emplyment History- Zip Code- Check if numeric
		if (document.sureform.pg1EmployerZip.value != "") {
			var strPg1Zip = document.sureform.pg1EmployerZip.value;
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Zip.length && boolResult == true; i++) {
				strPg1Char = strPg1Zip.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Employer Zip code error: valid characters are 0 through 9");
				document.sureform.pg1EmployerZip.focus();
				return false
			}
			else if (strPg1Zip.length != 5) {
				alert("Employer Zip code must be 5 digits");
				document.sureform.pg1EmployerZip.focus();
				return false
			}
		}
		 		
		//Employer Phone- check that area code is numeric
		if (document.sureform.pg1EmployerPhone1.value != "") {
			var strPg1Phone = document.sureform.pg1EmployerPhone1.value;
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;
  
			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Employer Phone Error:  Please only enter numerics for Area Code !");
				document.sureform.pg1EmployerPhone1.focus();
				return false
			}
			else if (strPg1Phone.length != 3) {
				alert("Employer Phone Error: Please enter 3 digit Area Code");
				document.sureform.pg1EmployerPhone1.focus();
				return false
			}
		}
 		
		//Employer Phone- area code is blank
		else {
			alert("Employer Phone Error:  Please enter Area Code !");
			document.sureform.pg1EmployerPhone1.focus();
			return false
		}
 
		//Employer Phone- check that next 3 digits are numeric
		if (document.sureform.pg1EmployerPhone2.value != "") {
			var strPg1Phone = document.sureform.pg1EmployerPhone2.value;
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Employer Phone Error:  Please only enter numerics for first 3 digits of phone number");
				document.sureform.pg1EmployerPhone2.focus();
				return false
			}
			
			else if (strPg1Phone.length != 3) {
				alert("Employer Phone Error: Please enter first 3 digits of phone number");
				document.sureform.pg1EmployerPhone2.focus();
				return false
			}
		}
		//Employer Phone- first 3 digits are blank
		else {
			alert("Employer Phone Error:  Please enter first 3 digits of phone number");
			document.sureform.pg1EmployerPhone2.focus();
			return false
		}
		
		//Employer Phone- check that last 4 digits are numeric
		if (document.sureform.pg1EmployerPhone3.value != "") {
			var strPg1Phone = document.sureform.pg1EmployerPhone3.value;
			
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Employer Phone Error:  Please only enter numerics for last 4 digits of phone number");
				document.sureform.pg1EmployerPhone3.focus();
				return false
			}
			
			else if (strPg1Phone.length != 4) {
				alert("Employer Phone Error: Please enter last 4 digits of phone number");
				document.sureform.pg1EmployerPhone3.focus();
				return false
			}
		}
		
		//Employer Phone- last 4 digits are blank
		else {
			alert("Employer1 Primary Phone Error:  Please enter last 4 digits of phone number");
			document.sureform.pg1EmployerPhone3.focus();
			return false
		}
 
		//Employer History- Immediate Supervisor
		if (document.sureform.pg1EmployerSupervisor.value == "") {	
			alert("Please Enter Employer Immediate Supervisor under Employment History !");
			document.sureform.pg1EmployerSupervisor.focus();
 			return false		
		} 

		//Employment History- Dates of Employment From Month
		var myindex=document.sureform.pg1EmployerFromMonth.selectedIndex;
		if (myindex==0) {
			alert("Emplyment History: Please select Dates of Emplyment: From: Month");
			document.sureform.pg1EmployerFromMonth.focus();
			return false
		}

		//Employment History- Dates of Employment From Year
		var myindex=document.sureform.pg1EmployerFromYear.selectedIndex;
		if (myindex == 0 ) {
			alert("Emplyment History: Please select Dates of Emplyment: From: Year");
			document.sureform.pg1EmployerFromYear.focus();
			return false
		}
  
		//Employment History- Dates of Employment To Month
		var myindex=document.sureform.pg1EmployerToMonth.selectedIndex;
		if (myindex==0) {
			alert("Emplyment History: Please select Dates of Emplyment: To: Month");
			document.sureform.pg1EmployerToMonth.focus();
			return false
		}

		//Employment History- Dates of Employment To Year
		var myindex=document.sureform.pg1EmployerToYear.selectedIndex;
		if (myindex==0 && document.sureform.pg1EmployerToMonth.value != "present") {
			alert("Emplyment History: Please select Dates of Emplyment: To: Year");
			document.sureform.pg1EmployerToYear.focus();
			return false
		}
 		
		//Emplyment History- Final Job Title
		if (document.sureform.pg1EmployerTitle.value == "") {
			alert("Employment History: Please Enter Final Job Title !");
			document.sureform.pg1EmployerTitle.focus();
			return false
		}
  		
		//Employment History- Final/Current Salary
		if (document.sureform.pg1EmployerSalary.value != "") {
			var strPg1Phone = document.sureform.pg1EmployerSalary.value;
			var strPg1ValidChars = "0123456789,.";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Employment History:  Please enter Final/Current Salary.  Valid characters are 0 through 9, comma  and decimal point !");
				document.sureform.pg1EmployerSalary.focus();
				return false
			}
		}
		//Employment History- Final/Current Salary is Blank
		else {
			alert("Employment History:  Please enter Final/Current Salary !");
			document.sureform.pg1EmployerSalary.focus();
			return false
		}
 
		//Employment History- Final/Current Salary Type
		var myindex=document.sureform.pg1EmployerSalaryType.selectedIndex;
		if (myindex==0) {
			alert("Emplyment History: Please select Final/Current Salary Type");
			document.sureform.pg1EmployerSalaryType.focus();
			return false
		}
 
		//Employment History- Reason For Leaving
		if (document.sureform.pg1EmployerReason.value == "") {
			alert("Employment History: Please Enter Reason For Leaving !");
			document.sureform.pg1EmployerReason.focus();
			return false
		}
 
		//Emplyment History- Summarize the nature of work
		if (document.sureform.pg1EmployerResponsibilities.value == "") {
			alert("Employment History: Please Enter Summary of the nature of work... !");
			document.sureform.pg1EmployerResponsibilities.focus();
			return false
		}
 		//Employment History- limit responsibilities to 255 characters
		if (document.sureform.pg1EmployerResponsibilities.value != "" && document.sureform.pg1EmployerResponsibilities.value.length > 255) {
			alert("Please limit the Summary of Employer 1 responsibilities to 255 characters");
			document.sureform.pg1EmployerResponsibilities.focus();
			return false
		}
 
		//Employment2 History- Zip Code- Check if numeric
		if (document.sureform.pg1Employer2Zip.value != "") {
			var strPg1Zip = document.sureform.pg1Employer2Zip.value;
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Zip.length && boolResult == true; i++) {
				strPg1Char = strPg1Zip.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Employer2 Zip code error: valid characters are 0 through 9");
				document.sureform.pg1Employer2Zip.focus();
				return false
			}
			else if (strPg1Zip.length != 5) {
				alert("Employer2 Zip code must be 5 digits");
				document.sureform.pg1Employer2Zip.focus();
				return false
			}
		}

		//Employer2 Phone- check that area code is numeric
		if (document.sureform.pg1Employer2Phone1.value != "") {
			var strPg1Phone = document.sureform.pg1Employer2Phone1.value;
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;
  
			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} 
			
			if (boolResult == false) {
				alert("Employer3 Phone Error:  Please only enter numerics for Area Code !");
				document.sureform.pg1Employer2Phone1.focus();
				return false
			}
			else if (strPg1Phone.length != 3) {
				alert("Employer3 Phone Error: Please enter 3 digit Area Code");
				document.sureform.pg1Employer2Phone1.focus();
				return false
			}
		}
 		
		//Employer2 Phone- check that next 3 digits are numeric
		if (document.sureform.pg1Employer2Phone1.value != "" && document.sureform.pg1Employer2Phone2.value != "") {
			var strPg1Phone = document.sureform.pg1Employer2Phone2.value;
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Employer2 Phone Error:  Please only enter numerics for first 3 digits of phone number");
				document.sureform.pg1Employer2Phone2.focus();
				return false
			}
			
			else if (strPg1Phone.length != 3) {
				alert("Employer2 Phone Error: Please enter first 3 digits of phone number");
				document.sureform.pg1Employer2Phone2.focus();
				return false
			}
		}
		//Employer2 Phone- first 3 digits are blank
		else if (document.sureform.pg1Employer2Phone1.value != ""){
			alert("Employer Phone Error:  Please enter first 3 digits of phone number");
			document.sureform.pg1Employer2Phone2.focus();
			return false
		}
		
		//Employer2 Phone- check that last 4 digits are numeric
		if (document.sureform.pg1Employer2Phone3.value != "" && document.sureform.pg1Employer2Phone1.value != "") {
			var strPg1Phone = document.sureform.pg1Employer2Phone3.value;
			
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Employer2 Phone Error:  Please only enter numerics for last 4 digits of phone number");
				document.sureform.pg1Employer2Phone3.focus();
				return false
			}
			
			else if (strPg1Phone.length != 4) {
				alert("Employer2 Phone Error: Please enter last 4 digits of phone number");
				document.sureform.pg1Employer2Phone3.focus();
				return false
			}
		}
		
		//Employer2 Phone- last 4 digits are blank
		else if(document.sureform.pg1Employer2Phone1.value != ""){
			alert("Employer2 Primary Phone Error:  Please enter last 4 digits of phone number");
			document.sureform.pg1Employer2Phone3.focus();
			return false
		}
  		
		//Employment2 History- Final Salary
		if (document.sureform.pg1Employer2Salary.value != "") {
			var strPg1Phone = document.sureform.pg1Employer2Salary.value;
			var strPg1ValidChars = "0123456789,.";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Employment History 2:  Please enter Final Salary.  Valid characters are 0 through 9, comma  and decimal point !");
				document.sureform.pg1Employer2Salary.focus();
				return false
			}
			var myindex=document.sureform.pg1Employer2SalaryType.selectedIndex;
			if (myindex==0) {
				alert("Employment History 2: Please select Final Salary Type");
				document.sureform.pg1Employer2SalaryType.focus();
				return false
			}
		}
  	
		//Employment2 History- limit responsibilities to 255 characters
		if (document.sureform.pg1Employer2Responsibilities.value != "" && document.sureform.pg1Employer2Responsibilities.value.length > 255) {
			alert("Please limit the Summary of Employer 2 responsibilities to 255 characters");
			document.sureform.pg1Employer2Responsibilities.focus();
			return false
		}
 
		//Employment3 History- Zip Code- Check if numeric
		if (document.sureform.pg1Employer3Zip.value != "") {
			var strPg1Zip = document.sureform.pg1Employer3Zip.value;
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Zip.length && boolResult == true; i++) {
				strPg1Char = strPg1Zip.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Employer3 Zip code error: valid characters are 0 through 9");
				document.sureform.pg1Employer3Zip.focus();
				return false
			}
			else if (strPg1Zip.length != 5) {
				alert("Employer3 Zip code must be 5 digits");
				document.sureform.pg1Employer3Zip.focus();
				return false
			}
		}


		//Employer3 Phone- check that area code is numeric
		if (document.sureform.pg1Employer3Phone1.value != "") {
			var strPg1Phone = document.sureform.pg1Employer3Phone1.value;
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;
  
			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Employer3 Phone Error:  Please only enter numerics for Area Code !");
				document.sureform.pg1Employer3Phone1.focus();
				return false
			}
			else if (strPg1Phone.length != 3) {
				alert("Employer3 Phone Error: Please enter 3 digit Area Code");
				document.sureform.pg1Employer3Phone1.focus();
				return false
			}
		}
 		
 
		//Employer3 Phone- check that next 3 digits are numeric
		if (document.sureform.pg1Employer3Phone1.value != "" && document.sureform.pg1Employer3Phone2.value != "") {
			var strPg1Phone = document.sureform.pg1Employer3Phone2.value;
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Employer3 Phone Error:  Please only enter numerics for first 3 digits of phone number");
				document.sureform.pg1Employer3Phone2.focus();
				return false
			}
			
			else if (strPg1Phone.length != 3) {
				alert("Employer3 Phone Error: Please enter first 3 digits of phone number");
				document.sureform.pg1Employer3Phone2.focus();
				return false
			}
		}
		//Employer3 Phone- first 3 digits are blank
		else if (document.sureform.pg1Employer3Phone1.value != ""){
			alert("Employer Phone Error:  Please enter first 3 digits of phone number");
			document.sureform.pg1Employer3Phone2.focus();
			return false
		}
		
		//Employer3 Phone- check that last 4 digits are numeric
		if (document.sureform.pg1Employer3Phone3.value != "" && document.sureform.pg1Employer3Phone1.value != "") {
			var strPg1Phone = document.sureform.pg1Employer3Phone3.value;
			
			var strPg1ValidChars = "0123456789";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Employer3 Phone Error:  Please only enter numerics for last 4 digits of phone number");
				document.sureform.pg1Employer3Phone3.focus();
				return false
			}
			
			else if (strPg1Phone.length != 4) {
				alert("Employer3 Phone Error: Please enter last 4 digits of phone number");
				document.sureform.pg1Employer3Phone3.focus();
				return false
			}
		}
		
		//Employer3 Phone- last 4 digits are blank
		else if(document.sureform.pg1Employer3Phone1.value != ""){
			alert("Employer3 Primary Phone Error:  Please enter last 4 digits of phone number");
			document.sureform.pg1Employer3Phone3.focus();
			return false
		}
 		
		//Employment3 History- Final Salary
		if (document.sureform.pg1Employer3Salary.value != "") {
			var strPg1Phone = document.sureform.pg1Employer3Salary.value;
			var strPg1ValidChars = "0123456789,.";
			var strPg1Char;
			var boolResult = true;

			for (i = 0; i < strPg1Phone.length && boolResult == true; i++) {
				strPg1Char = strPg1Phone.charAt(i);
				if (strPg1ValidChars.indexOf(strPg1Char) == -1)  
					boolResult = false;
			} // end for
			
			if (boolResult == false) {
				alert("Employment History 3:  Please enter Final salary.  Valid characters are 0 through 9, comma  and decimal point !");
				document.sureform.pg1Employer3Salary.focus();
				return false
			}
			var myindex=document.sureform.pg1Employer3SalaryType.selectedIndex;
			if (myindex==0) {
				alert("Emplyment History 3: Please select Final/Current Salary Type");
				document.sureform.pg1Employer3SalaryType.focus();
				return false
			}
		}
 		
 		//Employment History- limit responsibilities to 255 characters
		if (document.sureform.pg1Employer3Responsibilities.value != "" && document.sureform.pg1Employer3Responsibilities.value.length > 255) {
			alert("Please limit the Summary of Employer 3 responsibilities to 255 characters");
			document.sureform.pg1Employer3Responsibilities.focus();
			return false
		}
		
		//Limit Skills to 255 characters
		if (document.sureform.pg1Skills.value != "" && document.sureform.pg1Skills.value.length > 255) {
			alert("Please limit your skill summary to 255 characters");
			document.sureform.pg1Skills.focus();
			return false
		}

		//If all is good and no return false's		
		return true		
	}
	
	//function is executed when pushing one of the continue buttons
	function GoForward_p1() {
		if ( validate_p1() )  	
		    document.sureform.action = "employment2.asp"
			document.sureform.submit();
	} 
//-->


