<!--
//function to reset the background to white on focus for explorer
function rstBgnd(theElem) {

    var agt=navigator.userAgent.toLowerCase();

    var is_nav  = ((agt.indexOf('mozilla')!=-1) && (agt.indexOf('spoofer')==-1)
                && (agt.indexOf('compatible') == -1) && (agt.indexOf('opera')==-1)
                && (agt.indexOf('webtv')==-1));
    var isFf  = (agt.indexOf("firefox") != -1);

if (!is_nav || isFf){
    theElem.style.backgroundColor='#FFFFFF'; 
    theElem.style.color='#000000';
    }
}

function checkP(myForm) {

   var nameWarn = "";
   var noteWarn = "";
   var message = "";

    var agt=navigator.userAgent.toLowerCase();

    var is_nav  = ((agt.indexOf('mozilla')!=-1) && (agt.indexOf('spoofer')==-1)
                && (agt.indexOf('compatible') == -1) && (agt.indexOf('opera')==-1)
                && (agt.indexOf('webtv')==-1));
    var isFf  = (agt.indexOf("firefox") != -1);

if (!is_nav || isFf){
   if (isName(myForm.name.value) == false) {
        nameWarn = "Name;\r";
    myForm.name.style.backgroundColor="#FF0000";
    myForm.name.style.color="#000000";
   }

   if (isPhone(myForm.feedb.value) == false) {
        noteWarn = "Comment;\r";
    myForm.feedb.style.backgroundColor="#FF0000";
    myForm.feedb.style.color="#000000";
   }



    }
else { 
    if (isName(myForm.name.value) == false) {
        nameWarn = "Name;\r";
   }

   if (isPhone(myForm.feedb.value) == false) {
        noteWarn = "Comment;\r";
   }
}

var amessage="";
 if ( isName(myForm.name.value) == false || isPhone(myForm.feedb.value) == false){
    if (!is_nav || isFf){
            amessage = "Required fields are indicated in red on the form.\r\r"
    }  
     message = amessage+"Please re-enter the information for the following fields: \r" + nameWarn + noteWarn;
      alert(message);
      return false;
   }

}

function isPhone(element) {
  if (element != " " && element != null && element !=""){
      return true;}
  else return false;
}

function isEmail(element) {
   if (element.indexOf("@") != "-1" && element.indexOf(".") != "-1" &&
   element !=" " && element != null){
      return true;}
   else return false;
}

function isName(element) {
  if (element != " " && element != null && element !=""  && /\d/.test(element) == false){
      return true;}
  else {return false;}
}

function isNumber(element) {
  if (element != " " && element != null && element !=""  && /\D/.test(element) == false){
      return true;}
  else {return false;}
}

function isPassword(element) {
  if (element != " " && element != null && element !=""  && /\d/.test(element) == true && /\D/.test(element) == true){
      return true;
  } else {
    return false;
  }
}


// -->
