代码拉取完成,页面将自动刷新
同步操作将从 罗培中开发空间/php_study 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
<?php
/**
* TestGuest Version1.0
* ================================================
* Copy 2019-2021 ljcollege
* Web: http://www.ljcollege.com
* ================================================
* Author: Luo
* Date: 2020-9-2
*/
session_start();
//定义个常量,用来授权调用includes里面的文件
define('IN_TG',true);
//定义个常量,用来指定本页的内容
define('SCRIPT','member');
//引入公共文件
require dirname(__FILE__).'/includes/common.inc.php';
//是否正常登录
if (isset($_COOKIE['username'])) {
//获取数据
$_rows = _fetch_array("SELECT
tg_username,tg_sex,tg_face,tg_email,tg_url,tg_qq,tg_level,tg_reg_time
FROM
tg_user
WHERE
tg_username='{$_COOKIE['username']}'
LIMIT
1
");
if ($_rows) {
$_html= array();
$_html['username'] = $_rows['tg_username'];
$_html['sex'] = $_rows['tg_sex'];
$_html['face'] = $_rows['tg_face'];
$_html['email'] = $_rows['tg_email'];
$_html['url'] = $_rows['tg_url'];
$_html['qq'] = $_rows['tg_qq'];
$_html['reg_time'] = $_rows['tg_reg_time'];
switch ($_rows['tg_level']) {
case 0:
$_html['level'] = '普通会员';
break;
case 1:
$_html['level'] = '管理员';
break;
default:
$_html['level'] = '出错';
}
$_html = _html($_html);
} else {
_alert_back('此用户不存在');
}
} else {
_alert_back('非法登录');
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<?php
require ROOT_PATH.'includes/title.inc.php';
?>
</head>
<body>
<?php
require ROOT_PATH.'includes/header.inc.php';
?>
<div id="member">
<?php
require ROOT_PATH.'includes/member.inc.php';
?>
<div id="member_main">
<h2>会员管理中心</h2>
<dl>
<dd>用 户 名:<?php echo $_html['username']?></dd>
<dd>性 别:<?php echo $_html['sex']?></dd>
<dd>头 像:<?php echo $_html['face']?></dd>
<dd>电子邮件:<?php echo $_html['email']?></dd>
<dd>主 页:<?php echo $_html['url']?></dd>
<dd>Q Q:<?php echo $_html['qq']?></dd>
<dd>注册时间:<?php echo $_html['reg_time']?></dd>
<dd>身 份:<?php echo $_html['level']?></dd>
</dl>
</div>
</div>
<?php
require ROOT_PATH.'includes/footer.inc.php';
?>
</body>
</html>
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。