function FrontPage_Form1_Validator(theForm)
{
  var checkOK = "0123456789-.,";
  var checkStr = theForm.Square_Footage.value;
  var allValid = true;
  var validGroups = true;
  var decPoints = 0;
  var allNum = "";
  for (i = 0;  i < checkStr.length;  i++)
  {
    ch = checkStr.charAt(i);
    for (j = 0;  j < checkOK.length;  j++)
      if (ch == checkOK.charAt(j))
        break;
    if (j == checkOK.length)
    {
      allValid = false;
      break;
    }
    if (ch == ".")
    {
      allNum += ".";
      decPoints++;
    }
    else if (ch == "," && decPoints != 0)
    {
      validGroups = false;
      break;
    }
    else if (ch != ",")
      allNum += ch;
  }
  if (!allValid)
  {
    alert("Please enter only digit characters in the \"Square Footage\" field.");
    theForm.Square_Footage.focus();
    return (false);
  }

  if (decPoints > 1 || !validGroups)
  {
    alert("Please enter a valid number in the \"Square Footage\" field.");
    theForm.Square_Footage.focus();
    return (false);
  }

  var chkVal = allNum;
  var prsVal = parseFloat(allNum);
  if (chkVal != "" && !(prsVal >= "100"))
  {
    alert("Please enter a value greater than or equal to \"100\" in the \"Square Footage\" field.");
    theForm.Square_Footage.focus();
    return (false);
  }

  if (theForm.First_Name.value == "")
  {
    alert("Please enter a value for the \"First Name\" field.");
    theForm.First_Name.focus();
    return (false);
  }

  if (theForm.First_Name.value.length < 1)
  {
    alert("Please enter at least 1 characters in the \"First Name\" field.");
    theForm.First_Name.focus();
    return (false);
  }

  if (theForm.Last_Name.value == "")
  {
    alert("Please enter a value for the \"Last Name\" field.");
    theForm.Last_Name.focus();
    return (false);
  }

  if (theForm.Last_Name.value.length < 2)
  {
    alert("Please enter at least 2 characters in the \"Last Name\" field.");
    theForm.Last_Name.focus();
    return (false);
  }

  if (theForm.e_mail.value == "")
  {
    alert("Please enter a value for the \"email\" field.");
    theForm.e_mail.focus();
    return (false);
  }

  if (theForm.e_mail.value.length < 3)
  {
    alert("Please enter at least 3 characters in the \"email\" field.");
    theForm.e_mail.focus();
    return (false);
  }
  return (true);
}

function validate_home_value_form(theForm)
{

  if (theForm.Last_Name.value == "")
  {
    alert("Please enter a value for the \"Last Name\" field.");
    theForm.Last_Name.focus();
    return (false);
  }

  if (theForm.Last_Name.value.length < 2)
  {
    alert("Please enter at least 2 characters in the \"Last Name\" field.");
    theForm.Last_Name.focus();
    return (false);
  }

  if (theForm.e_mail.value == "")
  {
    alert("Please enter a value for the \"email\" field.");
    theForm.e_mail.focus();
    return (false);
  }

  if (theForm.e_mail.value.length < 3)
  {
    alert("Please enter at least 3 characters in the \"email\" field.");
    theForm.e_mail.focus();
    return (false);
  }

  if (theForm.Square_Footage.value == "")
  {
    alert("Please enter a value for the \"Square footage\" field.");
    theForm.Square_Footage.focus();
    return (false);
  }

  if (theForm.Square_Footage.value.length < 2)
  {
    alert("Please enter at least 2 characters in the \"Square footage\" field.");
    theForm.Square_Footage.focus();
    return (false);
  }

  var checkOK = "0123456789-.,";
  var checkStr = theForm.Square_Footage.value;
  var allValid = true;
  var validGroups = true;
  var decPoints = 0;
  var allNum = "";
  for (i = 0;  i < checkStr.length;  i++)
  {
    ch = checkStr.charAt(i);
    for (j = 0;  j < checkOK.length;  j++)
      if (ch == checkOK.charAt(j))
        break;
    if (j == checkOK.length)
    {
      allValid = false;
      break;
    }
    if (ch == ".")
    {
      allNum += ".";
      decPoints++;
    }
    else if (ch == "," && decPoints != 0)
    {
      validGroups = false;
      break;
    }
    else if (ch != ",")
      allNum += ch;
  }
  if (!allValid)
  {
    alert("Please enter only digit characters in the \"Square footage\" field.");
    theForm.Square_Footage.focus();
    return (false);
  }

  if (decPoints > 1 || !validGroups)
  {
    alert("Please enter a valid number in the \"Square footage\" field.");
    theForm.Square_Footage.focus();
    return (false);
  }
  return (true);
}

function validate_subscribe_form(theForm)
{
  if (theForm.First_Name.value == "" || theForm.First_Name.value.length < 1)
  {
    alert("Please enter at least an initial in the \"First Name\" field.");
    theForm.First_Name.focus();
    return (false);
  }

  if (theForm.Last_Name.value == "")
  {
    alert("Please enter a value for the \"Last Name\" field.");
    theForm.Last_Name.focus();
    return (false);
  }

  if (theForm.Last_Name.value.length < 2)
  {
    alert("Please enter at least 2 characters in the \"Last Name\" field.");
    theForm.Last_Name.focus();
    return (false);
  }

  if (theForm.e_mail.value == "")
  {
    alert("Please enter a value for the \"email\" field.");
    theForm.e_mail.focus();
    return (false);
  }
  return (true);
}

function validate_concierge_form(theForm)
{

  if (theForm.Last_Name.value == "")
  {
    alert("Please enter a value for the \"Last Name\" field.");
    theForm.Last_Name.focus();
    return (false);
  }

  if (theForm.Last_Name.value.length < 2)
  {
    alert("Please enter at least 2 characters in the \"Last Name\" field.");
    theForm.Last_Name.focus();
    return (false);
  }

  if (theForm.e_mail.value == "")
  {
    alert("Please enter a value for the \"email\" field.");
    theForm.e_mail.focus();
    return (false);
  }

  if (theForm.e_mail.value.length < 3)
  {
    alert("Please enter at least 3 characters in the \"email\" field.");
    theForm.e_mail.focus();
    return (false);
  }

  if (theForm.Question.value == "")
  {
    alert("Please enter a value for the \"Question\" field.");
    theForm.Question.focus();
    return (false);
  }

  if (theForm.Question.value.length < 2)
  {
    alert("Please enter at least 2 characters in the \"Question\" field.");
    theForm.Question.focus();
    return (false);
  }
  return (true);
}

function validate_askbroker_form(theForm)
{

  if (theForm.Last_Name.value == "")
  {
    alert("Please enter a value for the \"Last Name\" field.");
    theForm.Last_Name.focus();
    return (false);
  }

  if (theForm.Last_Name.value.length < 2)
  {
    alert("Please enter at least 2 characters in the \"Last Name\" field.");
    theForm.Last_Name.focus();
    return (false);
  }

  if (theForm.e_mail.value == "")
  {
    alert("Please enter a value for the \"email\" field.");
    theForm.e_mail.focus();
    return (false);
  }

  if (theForm.e_mail.value.length < 3)
  {
    alert("Please enter at least 3 characters in the \"email\" field.");
    theForm.e_mail.focus();
    return (false);
  }

  if (theForm.Question.value == "")
  {
    alert("Please enter a value for the \"Question\" field.");
    theForm.Question.focus();
    return (false);
  }

  if (theForm.Question.value.length < 2)
  {
    alert("Please enter at least 2 characters in the \"Question\" field.");
    theForm.Question.focus();
    return (false);
  }
  return (true);
}