<script>
function check(){
var name=document.getElementById("name").value;
var pass=document.getElementById("pass").value;
if(name=="账号" && pass=="密码"){
alert("登入成功");
window.document.f.action="shujubiao/";
window.document.f.submit();
}else{
alert("用户名或密码错误");
}
}
</script>
var errCount = 0;
function check() {
if (errCount < 3) {
var name = document.getElementById("name").value;
var pass = document.getElementById("pass").value;
if (name == "账号" && pass == "密码") {
errCount = 0;
alert("登入成功");
window.document.f.action = "shujubiao/";
window.document.f.submit();
} else {
errCount++;
alert("用户名或密码连续错误次数" + errCount);
}
}
if (errCount == 3) {// 连续输入3次账号密码错误
location.href = "登陆页地址..";
}
}
function check() {
var name = document.getElementById("name").value;
var pass = document.getElementById("pass").value;
if (name == "账号" && pass == "密码") {
alert("登入成功");
window.document.f.action = "shujubiao/";
window.document.f.submit();
} else {
alert("用户名或密码错误");
count++;
if (count >= 3) location = 'xxxxxx';
}
}