check.php
资源名称:Nsix.rar [点击查看]
上传用户:m68239277
上传日期:2014-10-12
资源大小:824k
文件大小:1k
源码类别:
Web服务器
开发平台:
PHP
- <?php
- if(!isset($_SESSION["user"])) echo "<script language='javascript'>alert('登录超时,请重新登录!');window.location='../index.php'</script>";
- $userf=$_SESSION["user"];
- $sqlon=mysql_query("select * from onuser where user_account='$userf' and sign='1'",$conn); //登录T出
- if(mysql_num_rows($sqlon)>0&&!isset($_SESSION["onyes"]))
- {
- echo "<script language='javascript'>alert('对不起,您的账号在别处登录,您被迫下线!');window.location.href='exit.php';</script>";
- }elseif(mysql_num_rows($sqlon)==0)
- {
- unset($_SESSION["onyes"]);
- }
- $sqltb_r=mysql_query("select tb_right from member where user_account='$userf'",$conn);
- if(mysql_num_rows($sqltb_r)>0){
- $_SESSION["tb_right"]=mysql_result($sqltb_r,0,"tb_right");
- }else{
- $_SESSION["tb_right"]=0;
- }
- ?>