// JavaScript Document used to validate foster inquiry form.
<!-- 
function validateForm(theForm) { 
 var Name = theForm.Name.value; 
 var Email = theForm.Email.value; 
 var Address = theForm.Address.value;
 var City = theForm.City.value;
 var Zip = theForm.Zip.value;
 var DayPhone = theForm.DayPhone.value;
 var EveningPhone = theForm.EveningPhone.value;
 
 if (Name == "") { 
   alert("Please fill in your name."); 
   theForm.Name.focus(); 
   return false; 
 } 
 if (Email == "") { 
   alert("A valid email address is required to process this form. Please enter a valid email address.");
   theForm.Email.focus();  
   return false; 
 } 
  if (Address == "") { 
   alert("Your mailing address is required to process this form. Please enter your mailing address.");
   theForm.Address.focus();  
   return false; 
 } 
   if (City == "") { 
   alert("You did not specify what city you live in. Please enter your city of residence.");
   theForm.City.focus();  
   return false; 
 } 
 if (theForm.County[theForm.County.selectedIndex].value == "") { 
 alert("You did not specify the county in which you reside. Please select your county.");
 theForm.County.focus(); 
 return false; 
 } 
 if (Zip == "") { 
 alert("You did not enter your zipcode. Please enter your zipcode.");
 theForm.Zip.focus();  
 return false; 
 }
 if (DayPhone == "") { 
 alert("You did not enter a daytime telephone number where you can be contacted. Please enter your daytime phone number.");
 theForm.DayPhone.focus();  
 return false; 
}
 if (EveningPhone == "") { 
 alert("You did not enter a telephone number where you can be contacted after work hours. Please enter your evening time phone number.");
 theForm.EveningPhone.focus();  
 return false; 
}
 if (!(theForm.BeenBefore[0].checked || theForm.BeenBefore[1].checked)) { 
 alert("You were asked if you have been a foster adoptive parent before and gave no response. Please select yes or no."); 
 theForm.BeenBefore[0].focus();
 return false; 
}
 if (!(theForm.AgeInterest[0].checked || theForm.AgeInterest[1].checked || theForm.AgeInterest[2].checked || theForm.AgeInterest[3].checked || theForm.AgeInterest[4].checked || theForm.AgeInterest[5].checked)) { 
 alert("You did not specify what ages of children you would be interested in. Please make a selection."); 
 theForm.AgeInterest[0].focus();
 return false; 
}
 if (!(theForm.CurrentAge[0].checked || theForm.CurrentAge[1].checked || theForm.CurrentAge[2].checked || theForm.CurrentAge[3].checked || theForm.CurrentAge[4].checked)) { 
 alert("You did not specify your age. Please make a selection."); 
 theForm.CurrentAge[0].focus();
 return false; 
 }
  if (!(theForm.Gender[0].checked || theForm.Gender[1].checked)) { 
 alert("You did not specify your gender. Please make a selection."); 
 theForm.Gender[0].focus();
 return false; 
}
 if (!(theForm.MaritalStatus[0].checked || theForm.MaritalStatus[1].checked || theForm.MaritalStatus[2].checked || theForm.MaritalStatus[3].checked)) { 
 alert("You did not specify your current marital status. Please make a selection."); 
 theForm.MaritalStatus[0].focus();
 return false; 
}
 if (!(theForm.ParticipateTraining[0].checked || theForm.ParticipateTraining[1].checked)) { 
 alert("You were asked if you would be willing to participate in training to learn new parenting skills and knowledge and gave no response. Please select yes or no."); 
 theForm.ParticipateTraining[0].focus();
 return false; 
}
 if (!(theForm.LearnMore[0].checked || theForm.LearnMore[1].checked)) { 
 alert("You were asked if you would be interested in learning more about becoming a foster adoptive parent and gave no response. Please select yes or no."); 
 theForm.LearnMore[0].focus();
 return false; 
}
 if (!(theForm.HomefinderCall[0].checked || theForm.HomefinderCall[1].checked)) { 
 alert("You were asked if you would like to have a homefinder call you and gave no response. Please select yes or no."); 
 theForm.HomefinderCall[0].focus();
 return false; 
}
 return true; 
} 
//--> 