function check_contact_form() {
    if ($('contact_form_firstname').getValue() == "") {
        alert("Please enter your first name.");
        return;
    }
    if ($('contact_form_lastname').getValue() == "") {
        alert("Please enter your last name.");
        return;
    }
    if ($('contact_form_email1').getValue() != $('contact_form_email2').getValue()) {
        alert("The email addresses don't match.");
        return;
    }
    if ($('contact_form_email1').getValue().search(/^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/) == -1) {
        alert("This does not seem to be a valid email address.");
        return; 
    }
    if ($('contact_form_dayphone').getValue() == "") {
        alert("We need at least one phone number from you.");
        return;
    }
    if ($('contact_form_citytown').getValue() == "") {
        alert("Please specify your city.");
        return;
    }
    if ($('contact_form_address').getValue() == "") {
        alert("Please specify the address for the job.");
        return;
    }    
    if ($('contact_form_state').getValue() == "") {
        alert("Please specify your state.");
        return;
    }    
    if ($('contact_form_zip').getValue() == "") {
        alert("Please specify your zip code.");
        return;
    }    
	if ($('contact_form_comments').getValue() == "") {
        alert("Please tell us as much as you can about the job in question.");
        return;
    }
    $('contact_register').value = '1';
    $('contact_form').submit();
}