// JavaScript Document
function CheckUserName(username)
{
  
  var url='check.asp?act=checkusername&username='+username+'';
  var xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
  xmlhttp.Open("get",url,false);
  xmlhttp.Send();
  //document.getElementById("timer").innerHTML = xmlhttp.responseText;
  if(xmlhttp.readyState==4)
    { //alert('kaishi');
	  if(xmlhttp.status==200)
	    {  
		  if(xmlhttp.responseText=="0")
		    {
			  //alert(xmlhttp.status);
			  document.getElementById("unamechk").innerHTML = '用户名长度不符合2-15或已被注册';
            }
		  else
		    {
			  document.getElementById("unamechk").innerHTML = '恭喜您!该用户名可以注册';
            }
		}
	}
  //location.reload();
  //alert(xmlhttp.responseText);
}

function PwdConfirm(userpwd,userpwdcfm)
{
  if(userpwdcfm!=userpwd)
	{
	//alert(xmlhttp.status);
	 document.getElementById("upwdcfm").innerHTML = '两次密码输入不相同';
    }
  else
    {
     document.getElementById("upwdcfm").innerHTML = '√';
    }
  //location.reload();
  //alert(xmlhttp.responseText);
}