<?php
error_reporting(0); 
session_start();
include("../../conn.php");
include("../../common.php");
if(!isset($_SESSION['username'])){echo "<script>alert('管理身份已失效请重新登录!')</script><script>top.location.href='../index.php'</script>";exit;}
$username=ubo($_SESSION['username']);
$sql1 = mysql_query("SELECT * FROM zhucema WHERE  user='$username'");
$row=mysql_fetch_array($sql1);
if($row[zdsl]!="1"){echo "<script>location.href='../index.php'</script>";}
?>
<!--头部-->
<!doctype html>
<html>
<head>
<meta charset="gb2312">
<link rel="stylesheet" type="text/css" href="newui/layui.css" />
<script type="text/javascript" src="newui/layui/layui.js"></script>
<title>头部</title>
<style type="text/css">
a{color:#FFF;}
a:hover{color:#FFF;}
ul,li{list-style-type: none;}
.flt{float: left;font-size: 18px;line-height: 36px;color: #c2c2c2;font-weight: bold;}	
.l{float: left;width: 250px;height: 36px;}
.l h2{font-size: 20px;line-height: 36px;color:#FFF;font-weight: bold;}
h1 {text-transform: uppercase;font-size: 85px;font-weight: 700;letter-spacing: 0.015em;}
h1::after {content: '';width: 80px;display: block;background: #fff;height: 10px;margin: 30px auto;line-height: 1.1;}
</style>
</head>
<body  class="layui-bg-cyan">
<div class="layui-fluid" style="border-bottom: #009688 solid 0px;line-height: 50px;height: 55px;">
<div class="layui-row layui-col-space10">
<div class="layui-col-md6">
<div class="l">
<h2>&nbsp;后台管理面板</h2>
</div> 
</div>
<div class="layui-col-md6">
<ul class=" layui-layout-right "lay-filter="">
<li class="layui-nav-item" style="float: left;padding: 0px 20px; "><a href="main.php" target="main">控制面板</a></li>
<li class="layui-nav-item" style="float: left;padding: 0px 20px; "><?php echo $admin?></li>
<li class="layui-nav-item" style="float: left;padding: 0px 20px; "><a href="javascript:;" onclick="repwd()">修改密码</a><span class="layui-badge-dot"></span></li>
<li class="layui-nav-item" style="float: left;padding: 0px 20px; "><a href="logout.php?logout=logout">退 出</a><span class="layui-badge-dot"></span></li>
</ul>
</div>
</div>
</div>
<script>
//注意：导航 依赖 element 模块，否则无法进行功能性操作
layui.use('element', function(){
var element = layui.element;
});
function repwd(){
	var pwd = prompt("请输入新密码","");
 if(pwd){
	 location.href="data/repwd.php?pwd="+pwd;
	
 }
}
</script>
</body>
</html>
