无为清净楼资源网 Design By www.qnjia.com

关于审核,如发表文章的审核、员工请假的审核、药品申请的审核等等,代码大同小异。

一.注册功能(zhece.php   chuli.php)

1.zhece.php

php注册审核重点解析(数据访问)

<!DOCTYPE html>
<html>
 <head>
  <meta charset="UTF-8">
  <title></title>
 </head>
 <form method="post" action="chuli.php">
 <div style="margin:10px 500px"> 
   <h2 > &nbsp;&nbsp; &nbsp; &nbsp; 注册页面</h2>
  <div>用户名:<input type="text" name="users"/></div><br />
  <div>密码:<input type="text" name="pwd"/></div><br />
  <div>姓名:<input type="text" name="name"/></div><br />
  <div>性别:<input type="text" name="sex"/></div><br />
  <div>生日:<input type="text" name="birthday"/></div><br />
  <input type="submit" value="注册" />
  <a href="denglu.php" rel="external nofollow" >已有账号,立即登录</a>
  </div>
 </form>
 <body>
 </body>
</html>

2.chuli.php

<"users"];
$pwd = $_POST["pwd"];
$name= $_POST["name"];
$sex = $_POST["sex"];
$birthday = $_POST["birthday"];
require "DBDA.class.php";
$db = new DBDA();
$sql = "insert into users values ('{$users}','{$pwd}','{$name}',{$sex},'{$birthday}',0)";
if($db->query($sql,0)){
header("location:zhuce.php"); 
 
}
"text-align: center">php注册审核重点解析(数据访问)

1.denglu.php

<!DOCTYPE html>
<html>
 <head>
  <meta charset="UTF-8">
  <title></title>
 </head>
 <body>
  <form method="post" action="login.php">
 <div style="margin:100px 500px"> 
   <h2 > &nbsp;&nbsp; &nbsp; &nbsp; 登录页面</h2>
  <div>用户名:<input type="text" name="users"/></div><br />
  <div>密码:<input type="text" name="pwd"/></div><br />
  <input type="submit" value="登录" />
  <a href="zhuce.php" rel="external nofollow" >没有账号,立即注册</a>
  </div>
 </form>
 </body>
</html>

2.login.php

<"users"];
$pwd = $_POST["pwd"];
require "DBDA.class1.php";
$db = new DBDA();
$sql = "select * from users where users = '{$users}'";
$arr = $db->query($sql);

//$arr[0][1] 密码
//$arr[0][5] 审核状态


if($arr[0][1] == $pwd && !empty($pwd))
{
 if($arr[0][5])
 {
  echo "登录成功!";
 }
 else{
  echo "审核未通过!";
 }
}
else{
 echo "用户名或密码错误!";
}

"text-align: center">php注册审核重点解析(数据访问)

1.guanliyuan.php

<!DOCTYPE html>
<html>
 <head>
  <meta charset="UTF-8">
  <title></title>
 </head>

<body>
<h1>管理员审核</h1>
<table width="100%" border="1" cellpadding="0" cellspacing="0">
 <tr>
  <td>用户名</td>
  <td>密码</td>
  <td>姓名</td>
  <td>性别</td>
  <td>生日</td>
  <td>操作</td>
 </tr>
 <"DBDA.class1.php";
 $db = new DBDA();
 
 $sql = "select * from users";
 $arr = $db->query($sql);
 
 foreach($arr as $v)
 {
  $str = "";
  if($v[5])
  {
   $str = "<span style='color:green'>已通过</span>
   <a href='chexiao.php";
  }
  else
  {
   $str = "<a href='tongguo.php";
  }
  
  echo "<tr>
  <td>{$v[0]}</td>
  <td>{$v[1]}</td>
  <td>{$v[2]}</td>
  <td>{$v[3]}</td>
  <td>{$v[4]}</td>
  <td>{$str}</td>
 </tr>";
 }
 "htmlcode">
<"uid"];
require "DBDA.class.php";
$db = new DBDA();
$sql = "update users set isok=1 where uid='{$uid}'";
$db->query($sql,0);
header("location:guanliyuan.php");

3.chexiao.php

<"uid"];
require "DBDA.class.php";
$db = new DBDA();
$sql = "update users set isok=0 where uid='{$uid}'";
$db->query($sql,0);
header("location:guanliyuan.php");

以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持。

标签:
php,注册

无为清净楼资源网 Design By www.qnjia.com
广告合作:本站广告合作请联系QQ:858582 申请时备注:广告合作(否则不回)
免责声明:本站文章均来自网站采集或用户投稿,网站不提供任何软件下载或自行开发的软件! 如有用户或公司发现本站内容信息存在侵权行为,请邮件告知! 858582#qq.com
无为清净楼资源网 Design By www.qnjia.com

RTX 5090要首发 性能要翻倍!三星展示GDDR7显存

三星在GTC上展示了专为下一代游戏GPU设计的GDDR7内存。

首次推出的GDDR7内存模块密度为16GB,每个模块容量为2GB。其速度预设为32 Gbps(PAM3),但也可以降至28 Gbps,以提高产量和初始阶段的整体性能和成本效益。

据三星表示,GDDR7内存的能效将提高20%,同时工作电压仅为1.1V,低于标准的1.2V。通过采用更新的封装材料和优化的电路设计,使得在高速运行时的发热量降低,GDDR7的热阻比GDDR6降低了70%。