COOKIE SESSION
来源:互联网 发布:80端口怎么看 编辑:程序博客网 时间:2024/05/15 01:47
<?
session_start();
if(!isset($_SESSION['admin'])){
//验证是否设置了cookie
if(isset($_COOKIE['admin_id'])){
$sql="select * from where user_id=1";
include 'includes/db.class.php';
$db=new db('localhost','ecshop_test','root','');
$row=$db->getRow($sql);
$password=$row['password'];
if($password!=$_COOKIE['admin_pass']){
header ('Location:privilege.php');
}
}else{
header('Location:privilege.php');
}
}
?>
session_start();
if(!isset($_SESSION['admin'])){
//验证是否设置了cookie
if(isset($_COOKIE['admin_id'])){
$sql="select * from where user_id=1";
include 'includes/db.class.php';
$db=new db('localhost','ecshop_test','root','');
$row=$db->getRow($sql);
$password=$row['password'];
if($password!=$_COOKIE['admin_pass']){
header ('Location:privilege.php');
}
}else{
header('Location:privilege.php');
}
}
?>
- Session,Cookie
- cookie & session
- Cookie & Session
- Session, Cookie
- Session、Cookie
- SESSION && COOKIE
- Cookie & Session
- SESSION && COOKIE
- Session.Cookie
- cookie session
- session cookie
- session cookie
- Cookie&Session
- cookie session
- Cookie&Session
- Cookie、Session
- cookie&session
- Cookie & Session
- How to Change the DBID and the DBNAME by using NID [ID 224266.1]
- CentOS Linux VPS 安装X-Window
- Oracle Linux 安装X Window 图形界面
- Allegro多个元器件同时旋转操作方法
- 解决centos6 的virt-manager 无法创建network interface问题
- COOKIE SESSION
- 开源 免费 java CMS - FreeCMS1.5 标签 infoPreList
- 对下拉可选框的总结
- Linux的X-WINDOW的需要安装包
- Session and Distribution
- Sublime Text 2 设置文件详解
- 01背包
- 在线旅游市场,谷歌向左,百度向右
- 每天学点Linux:八