日期:2014-05-17 浏览次数:20469 次
$account=$_POST["account"];
$password=$_POST["password"];
$res=mysql_query("select * from z_register where z_account='".$account."' and z_password='".$password."'");
print_r($res);
if($result=mysql_fetch_array($res)){
mysql_query("update z_register set z_login_count = z_login_count+1 where z_account='".$account."'");
$_SESSION['account']=$account;
$_SESSION['username']=$result['z_name'].$result['z_title'];
//$_SESSION['login_count']=$result['z_login_count'];
refresh_page("./other/list.php");
}else{
exit('登录失败!点击此处 <a href="javascript:history.back(-1);">返回</a> 重试<br/>');
}