function validate_required(field,alerttxt)
{
with (field)
  {
  if (value==null||value=="")
    {
    alert(alerttxt);return false;
    }
  else
    {
    return true;
    }
  }
}

function validate_form(thisform)
{
with (thisform)
  {
  if (validate_required(email,"You must enter an email address!")==false)
  {email.focus();return false;}
  if (validate_required(message,"You must enter a message!")==false)
  {message.focus();return false;}
  }
}

function hidenote(which){
		if(which.value=="username"){
			which.title = which.value;
			which.value ="";
		}
		which.style.backgroundImage = "none";
	}

function hidenotep(which){
		if(which.value=="password"){
			which.title = which.value;
			which.value ="";
		}
		which.style.backgroundImage = "none";
	}
