
function chkagt(theForm) {
	if (theForm.account.value=="")
	{
		alert("请输入您的帐号！");
		theForm.account.focus();
		return (false);
	}
	if ((theForm.account.value.length<5)||(theForm.pass.value.length<5))
	{
		alert("帐号或密码的长度不能小于5！")
		return (false);
	}
	if (theForm.pass.value=="")
	{
		alert("请输入您的密码！");
		theForm.pass.focus();
		return (false);
	}
    if (theForm.name.value =="")
    {
      alert("请输入您的公司名称！");
      theForm.name.focus();
      return (false);
    }
	if (theForm.addr.value=="")
	{
		alert("请输入公司地址！");
		theForm.addr.focus();
		return (false);
	}
	if (theForm.postcode.value=="")
	{
		alert("请输入邮编！");
		theForm.postcode.focus();
		return (false);
	}
	
    if (theForm.email.value == "")
    {
      alert("请输入您的电子邮件！");
      theForm.email.focus();
      return (false);
    }

    if (theForm.email.value.length <7 )
    {
      alert("您输入的电子邮件不符合规范\n请重新输入您的电子邮件！");
      theForm.email.focus();
      return (false);
    }
    var strEmail = theForm.email.value;

    if (strEmail != "" && (strEmail.indexOf("@") == -1 || strEmail.indexOf(".") == -1))
    {
      alert("您输入的电子邮件地址不符合规范，请您重新输入您的电子邮件地址！");
      theForm.email.focus();
      return (false);
    }
	if (theForm.phone.value=="")
	{
		alert("请输入电话号码！");
		theForm.phone.focus();
		return (false);
	}
	if (theForm.phone.value.length<7)
	{
		alert("电话号码不符合规范!");
		theForm.phone.focus();
		return (false);
	}
	return true;

}

