﻿function get_Code() {
	var CodeFile = "/Inc/CodeImg.aspx";
	if(document.getElementById("ImgCode"))
		document.getElementById("ImgCode").innerHTML = '<img src="'+CodeFile+'?t='+Math.random()+'" alt="点击刷新验证码" style="cursor:pointer;border:0;vertical-align:middle;" onclick="this.src=\''+CodeFile+'?t=\'+Math.random()" />'
}
$(function(){
    $("#txtPassWord").bind("focus",function(){
       if($("#txtUserName").val().length>0)
       {
          $("#showcheckcode").show(100);
       }
    });
});
function ChkLogin()
{
	var UN=document.getElementById("txtUserName");
	var PW=document.getElementById("txtPassWord");
	var CN=document.getElementById("txtCheckCode");
	
	if (UN.value==""){
		UN.focus();
		alert("请输入您的用户名");
		return false;
	}	
	if (PW.value==""){
		PW.focus();
		alert("您的密码不能为空");
		return false;
	}	
	if (CN.value==""){
		CN.focus();
		alert("请输入验证码！");
		return false;
	}
}