?? index_login.js
字號:
function loginCheck(){
var theForm=document.getElementById("loginForm");
with(theForm){
if(username.value==""){
alert("用戶名不能為空!");
username.focus();
return false;
}
else if(userpass.value==""){
alert("密碼不能為空!");
userpass.focus();
return false;
}
userpass.value=MD5(userpass.value);
sendCheck(username.value,userpass.value);
}
}
function sendCheck(user,pass){
var url = "admin/checkIndexLogin.asp?username=" + escape(user) + "&userpass=" + escape(pass);
xmlHttp.open("GET", url, true);
xmlHttp.onreadystatechange = ifLoginOk;
xmlHttp.send(null);
}
function ifLoginOk(){
if (xmlHttp.readyState == 4) {
var response = xmlHttp.responseText;
if(response.indexOf("|")>0){
var arrRs=response.split("|");
location.href=arrRs[1];
}else{
alert(response);
document.getElementById("username").focus();
}
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -