document.write("
");
$().ready(function(){
$('#index_login').submit(function(){
checkFrom();
return false;
});
});
function checkFrom(){
if($('#uname').val()=='' || $('#pass').val()==''){
alert('请填写用户名和密码再登录!');
}else{
var ret_val = $.post('http://www.zfa.cn/login/a_login.php',
{uname:$('#uname').val(), pass:$('#pass').val()},
function(ret){
switch(ret){
case '-3':
alert('用户名或密码不正确!');
break;
case '-2':
alert('用户名不正确!');
break;
case '-1':
alert('密码不正确!');
break;
default :
$('#user_name').html(ret);
$('#no_log').hide();
$('#is_log').show();
$('#index_login')[0].submit();
}
}
);
}
}