<!-- Hide from old browsers

// Copyright © 1999 Doug Popeney
// Created by Doug Popeney (easyjava@easyjavascipt.com)
// JavaScript Made Easy!! - http://www.easyjavascript.com

// This script checks the entries made on the form to see if whether empty or incorrect.
// A message is given if all correct telling user details have been sent.
// A message is also given if entries are incorrect telling user what errors have occurred.

function validate_form() {
missinginfo = "";
  validity = true; // assume valid
    validity = true; // assume valid
  if (!check_empty(document.form.Name.value))
        { validity = false; missinginfo += ("\n- Please enter your name");}
  if (!check_email(document.form.Email.value))
        { validity = false; missinginfo += ("\n- Your Email Address appears to be incorrect"); }
  if (validity) {}
  else {missinginfo = ("\nINCORRECT DATA ENTRY" + "\n_____________________________\n"
 + missinginfo + "\n_____________________________" + "\n\nPlease re-enter and submit again!");
  alert(missinginfo);}

  return validity;
}

function check_empty(text) {
  return (text.length > 0); // returns false if empty
}

function check_email(address) {
  if ((address == "")
    || (address.indexOf ('@') == -1)
    || (address.indexOf ('.') == -1))
      return false;
  return true;
}


// --End Hiding Here -->