
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Welcome</title>
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<link rel="stylesheet" href="/Contents/Styles/nu/cui.css?v=16101601" />
<link rel="stylesheet" href="/Contents/Styles/nu/lib.css?v=16101601" />
<link rel="stylesheet" href="/Contents/Styles/nu/style.css?v=16101601" />
<script type="text/javascript" src="//libs.baidu.com/jquery/1.11.1/jquery.min.js"></script>
<script src="/Contents/Scripts/login.min.js?v=20190420002" type="text/javascript"></script>
<script type="text/javascript">
var btnflag = true;
var vcodeverify = 0;
/// if (top.location == self.location) top.location = '/Admin';
document.onkeydown = function (e) {
if (!e) e = window.event;
if ((e.keyCode || e.which) == 13) {
if (btnflag == true) checkLogin();
}
}
$('#txtUid').keyup(function (e) {
if (!e) e = window.event;
if ((e.keyCode || e.which) == 13) {
$("#txtPwd").focus();
}
});
$('#txtPwd').keyup(function (e) {
if (!e) e = window.event;
if ((e.keyCode || e.which) == 13) {
$("#txtCode").focus();
}
});
$('#txtCode').keyup(function (e) {
if (!e) e = window.event;
if ((e.keyCode || e.which) == 13) {
if (btnflag == true) checkLogin();
}
});
function checkLogin() {
btnflag = false;
if ($("#txtUid").val() == '') {
alert("请输入 會員帳號!");
$("#txtUid").focus();
btnflag = true;
return false;
}
if ($("#txtPwd").val() == '') {
alert("请输入 會員密碼!");
$("#txtPwd").focus();
btnflag = true;
return false;
}
if ($("#txtCode").val().length < 4) {
alert("请输入 驗證碼!");
$("#txtCode").focus();
btnflag = true;
return false;
}
$('#btnsubmit').attr("disabled", true);
var c = buildCode();
$.post('/Admin/login/CheckLogin?r=' + Math.random(), { code: c }, function (resp) {
$('#btnsubmit').attr("disabled", false);
if (resp.success) {
try {
window.parent.setwebtitle(resp.webtitle);
self.location.href = resp.url;
} catch (e) {
self.location.href = resp.homeurl;
}
} else {
reloadCode();
$("#txtCode").select();
alert(resp.message);
}
btnflag = true;
}, 'json').error(function () {
$('#btnsubmit').attr("disabled", false);
btnflag = true;
});
}
function reloadCode() {
$('#imgCode').attr('src', '/Image/VerifyCodeN?r=' + Math.random());
}
$(function () {
$('#txtUid').focus();
$(document).bind("contextmenu", function (e) { return false });
// document.oncontextmenu = function (e) { return false; }
//reloadCode();
});
</script>
</head>
<body class="bd-login">
<div class="box-login">
<h2 class="tit"> </h2>
<ul class="ul-form">
<li>
<input type="text" id="txtUid" name="txtUserNo" tabindex="1" oncopy="return false" onpaste="return false" maxlength="20" class="inp-login inp1" >
</li>
<li>
<input type="password" tabindex="2" name="txtPwd" id="txtPwd" oncopy="return false" onpaste="return false" maxlength="20" class="inp-login inp2" >
</li>
<li>
<input type="text" id="txtCode" name="txtCode" tabindex="3" maxlength="4" autocomplete="off" disableautocomplete="" class="inp-login inp3" >
<img id="imgCode" src="/Image/VerifyCodeN?r=0.2019062001471909958261" alt="刷新驗證碼" onclick="reloadCode()" style="cursor:pointer;" class="img-valid"/>
</li>
<li>
<input type="hidden" id="txtVer" name="txtVer" value="yk3ctkpwbxbkkxcqj2fh3pmy"/>
<input type="button" value="登錄" class="btn-login" onclick="checkLogin()" />
<div style="font-size: 11px;color:#cccc00">Copyright © Microsoft 2016</div>
</li>
</ul>
</div>
<div style="clear:both;"></div>
</body>
</html
来源:CSDN
作者:QQ534648575
链接:https://blog.csdn.net/QQ534648575/article/details/103531906