<!-- 
function addbookmark()
{
bookmarkurl="http://www.1617.com.cn/"
bookmarktitle="一流仪器网"
if (document.all)
window.external.AddFavorite(bookmarkurl,bookmarktitle)
}

function click() {
if (event.button==2) { 
alert('对不起,禁止使用此功能.')
}
}
document.onmousedown=click

function check_seach(theForm)
{
   if (theForm.keys.value =="" || theForm.keys.value =="请输入产品关键字")
    {
      alert("请填写关键字!");
      theForm.keys.focus();
      return false;
    }
 return (true);
}

function check_login(theForm)
/*验证登录表单*/
{
  if (theForm.u_name.value =="")
    {
      alert("请输入用户名!");
      theForm.u_name.focus();
      return false;
    }
  if (theForm.u_pwd.value =="")
    {
      alert("请输入用户密码!");
      theForm.u_pwd.focus();
      return false;
    }
}


/*检查E_mail的输入正确性*/
function check_email(str)
{
var k=str.indexOf(" ");   
var a=str.indexOf("@");
var b=str.indexOf(".");
var l=str.length-1;
var c=b-a;
	  
if (k>=0 || a<=0 || b<0 || c<2 || b==l)
{ return false;}
return (true);
}

/*检查用户名输入的正确性。以字母、数字和下划线组成。*/
function check_username(str)
{
 var Letters = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890_";
 var i;
 var c;
 if (str == "" || str.length<6) return false;
 if (str.indexOf(" ")>0) return false;
 for( i = 0; i < str.length; i ++ )
 {
  c = str.charAt( i );
  if (Letters.indexOf( c ) < 0)
  return false;
 }
 return true;
}
/*检查电话信息输入的正确性。以数字和,.+()/-&组成。*/
function check_telphone(str)
{
 var Letters = "0123456789,.+()/-&";
 var i;
 var c;
 if (str == "" ) return false;
 if (str.indexOf(" ")>0) return false;
 for( i = 0; i < str.length; i ++ )
 {
  c = str.charAt( i );
  if (Letters.indexOf( c ) < 0)
  return false;
 }
 return true;
}
function check_zip(str)
{
 var Letters = "0123456789";
 var i;
 var c;
 if (str == "" ) return false;
 if (str.indexOf(" ")>0) return false;
 if (str.length!=6) return false;
 for( i = 0; i < str.length; i ++ )
 {
  c = str.charAt( i );
  if (Letters.indexOf( c ) < 0)
  return false;
 }
 return true;
}
function checkReg(theForm)
{
  
  if (!check_username(theForm.u_name.value))
  {
     alert("提示：\n\n您填写的用户名无效；\n\n请填写一个有效的用户名；\n\n以字母、数字和“_”组成；\n\n最少6位；\n\n不要有写空格。\n");
     theForm.u_name.focus();
     return false; 
  }
  if (theForm.u_pwd0.value=="")
  {
     alert("提示：您填写的用户密码。");
	 theForm.u_pwd0.focus();
	 return false; 
  }
  if (theForm.u_pwd1.value!=theForm.u_pwd0.value)
  {
     alert("提示：您填写的确认密码与用户密码不同！");
	 theForm.u_pwd1.focus();
	 return false; 
  }
  if (theForm.t_name.value=="")
  {
     alert("提示：您填写的真实姓名。");
	 theForm.t_name.focus();
	 return false; 
  }
  if (theForm.u_region.value==0)
  {
     alert("提示：请您选择所在地区。");
	 theForm.u_region.focus();
	 return false; 
  }
  if (theForm.u_address.value=="")
  {
     alert("提示：请您填写详细地址。");
	 theForm.u_address.focus();
	 return false;
  }
  if (!check_zip(theForm.u_zip.value))
  {
     alert("提示：\n\n您填写的邮编信息无效；\n\n请填写一个有效的邮编信息；\n\n以6位数字组成；\n\n不要有写空格。\n");
     theForm.u_zip.focus();
     return false; 
  }
  if (!check_telphone(theForm.u_tel.value))
  {
     alert("提示：\n\n您填写的电话信息无效；\n\n请填写一个有效的电话信息；\n\n以数字和“,.+()/-&”组成；\n\n不要有写空格。\n");
     theForm.u_tel.focus();
     return false; 
  }
  if (!check_email(theForm.u_email.value))
  {
     alert("提示：\n\n您填写的EMAIL无效；\n\n请填写一个有效的EMAIL；\n\n不要有写空格。\n");
     theForm.u_email.focus();
     return false; 
  } 
 return true;
}

function check_pwd(theForm)
/*密码找回表单验证*/
{  
  if (theForm.u_name.value=="")
  {
     alert("提示：\n\n您填写的用户名无效!\n");
     theForm.u_name.focus();
     return false; 
  }
  if (!check_email(theForm.u_email.value))
  {
     alert("提示：\n\n您填写的EMAIL无效；\n\n请填写一个有效的EMAIL；\n\n不要有写空格。\n");
     theForm.u_email.focus();
     return false; 
  } 
 return true;
}

function checkFankui(theForm)
{
  if (theForm.u_name.value=="")
  {
     alert("提示：请您填写真实姓名。");
	 theForm.u_name.focus();
	 return false; 
  }
  if (!check_telphone(theForm.u_tel.value))
  {
     alert("提示：\n\n您填写的电话信息无效；\n\n请填写一个有效的电话信息；\n\n以数字和“,.+()/-&”组成；\n\n不要有写空格。\n");
     theForm.u_tel.focus();
     return false; 
  }
  if (!check_email(theForm.u_email.value))
  {
     alert("提示：\n\n您填写的EMAIL无效；\n\n请填写一个有效的EMAIL；\n\n不要有写空格。\n");
     theForm.u_email.focus();
     return false; 
  } 
  if (theForm.e_tltle.value=="")
  {
     alert("提示：请您填写E_mail标题。");
	 theForm.e_tltle.focus();
	 return false; 
  }
  if (theForm.e_text.value=="")
  {
     alert("提示：请您填写E_mail内容。");
	 theForm.e_text.focus();
	 return false; 
  }
 return true;
}
function check_bbs(theForm)
{
  if (theForm.b_title.value =="")
    {
      alert("请填写标题！");
      theForm.b_title.focus();
      return false;
    }
  if (theForm.b_info.value =="")
    {
      alert("请填写内容！");
      theForm.b_info.focus();
      return false;
    }
  return true;	
}
-->