Thanks. Yeah, I think that makes sense. Two more clarifying questions.
Where exactly should this
if (empty($avail)) {
$error = "required";
}
appear within the php code:
<?php
$avail = '';
foreach ($availability as $val)
$avail .= $val.", ";
$tech = ''; foreach ($techSkills as $val)
$tech .= $val.", ";
$act = ''; foreach ($activities as $val)
$act .= $val.", ";
$formsent = mail("email@email.org", "Volunteer Form: $name", "Name: $name\r\n\r\nJob email: $email\r\n\r\nPhone: $phone\r\n\r\nAdress: $address\r\n\r\ncity: $city\r\n\r\nstate: $state\r\n\r\nZipCode: $zipCode\r\n\r\nbirthdate: $birthmonth $birthdate $birthyear\r\n\r\nCollege or Certificates: $college\r\n\r\nnative Tongue: $language\r\n\r\nOther Languages: $addlLanguages\r\n\r\nTimes Available: $avail\r\n\r\nHow Often: $howOften\r\n\r\nSpecialities: $skills\r\n\r\nSkills: $tech\r\n\r\nExperience: $youngLearners\r\n\r\nWilling to Participate in: $act\r\n\r\nHow Did You Hear ABout Us?: $hearAbout\r\n\r\nDo you have a car? $car\r\n\r\nType of Agent: $agent");
header("Location:http://www.website.com");
?>
And where exactly in the form page should this be?
if (empty($error)) {
} else {
if ($error == 'required') {
$msg = "You left the field blank.";
} elseif ($error == 'anything') {
$msg = "any error you want or another field that can't be blank";
}
Within the <FORM> tags? After or before the submit button? At the top of the form? Does it matter where it appears?
THANKS AGAIN FOR YOUR HELP!