<!--#include file=conn.asp-->
<!--#include file=cookies.asp-->
<%
dim flag
flag=request.cookies("foxwww")("fox")
if flag<9 then
response.Write "<script LANGUAGE='javascript'>alert('你目前的级别不允许此操作！');history.go(-1);</script>"
response.end
end if
if flag=10 then
response.Write "<script LANGUAGE='javascript'>alert('您只是后台测试员，请注意身份！');window.location='right.asp';</script>"
response.end
end if%>
<link rel="stylesheet" type="text/css" href="images/fox.css">
<style type=text/css>
BODY{
	margin:0px;
	FONT-SIZE: 12px;
	FONT-FAMILY: "宋体", "Verdana", "Arial", "Helvetica", "sans-serif";
	background-color: #CCCC99; 
	scrollbar-highlight-color: #CC9933; 
	scrollbar-arrow-color: #FFFFFF; 
	scrollbar-base-color: #CC9933
}
table { border:0px; }
td { font:normal 12px 宋体; }
img { vertical-align:bottom; border:0px; }
a { font:normal 12px 宋体; color:#111111; text-decoration:none; }
a:hover { color:#384780;text-decoration:underline; }
.sec_menu { border-left:2px solid #CC3300; border-right:2px solid #CC3300; border-bottom:2px solid #CC3300; overflow:hidden; background:#ffffff; }
.menu_title {background-color: #335EA8;color: white;font-size: 12px;font-weight:bold;height: 25; }
.menu_title span { position:relative; top:2px; left:8px; color:#FFFF00; font-weight:bold; }
.menu_title2 {background-color: #335EA8;color: white;font-size: 12px;font-weight:bold;height: 25; }
.menu_title2 span { position:relative; top:2px; left:8px; color:#FEFEFE; font-weight:bold; }
input,select,Textarea{
font-family:宋体,Verdana, Arial, Helvetica, sans-serif; font-size: 12px;}
</style>

<div align="center">
  <form method="POST" action="admin_addchk.asp">
  <center>
  <table style="border-width:1px; BORDER-COLLAPSE: collapse" borderColor="#CC0000" height="68" cellSpacing="0" cellPadding="0" width="100%" border="1">
    <tr>
      <td bgColor="#CC0000" height="28">
      <p align="left" class="style1"><font size="2">&nbsp;</font><font color="#FFFFFF">增加管理员</font></td>
    </tr>
    <tr>
      <td height="25" align="middle" bgcolor="#FFFFFF" style="BORDER-BOTTOM: medium none"><div align="left"><br>
          <span class="style1"><font size="2">&nbsp;</font><font size="2">&nbsp;&nbsp;</font></span>用户名：
            <input name="username" size="29" maxlength="20">
      </div></td>
    </tr>
    <tr>
      <td height="25" align="middle" bgcolor="#FFFFFF" style="BORDER-TOP: medium none; BORDER-BOTTOM: medium none"><div align="left"><span class="style1"><font size="2">&nbsp;</font><font size="2">&nbsp;</font><font size="2">&nbsp;</font></span>密&nbsp; 码：
            <input name="password" size="29" maxlength="20">
      </div></td>
    </tr>
    <tr>
      <td height="25" align="middle" bgcolor="#FFFFFF" style="BORDER-TOP: medium none; BORDER-BOTTOM: medium none"><div align="left"><span class="style1"><font size="2">&nbsp;</font><font size="2">&nbsp;</font><font size="2">&nbsp;</font></span>权&nbsp; 限：
       
		<select size="1" name="quan">
		<option value="6" selected>网站审核员</option>
		<option value="7">网店管理员</option>
		<option value="8">分类设置员</option>
		<option value="9">最高管理员</option>
		</select></div></td>
    </tr>
    <tr>
      <td height="25" bgcolor="#FFFFFF" style="BORDER-TOP: medium none"><p align="center">      
        <table width="100%"  border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td><div align="center">
              <input type="submit" value="确认添加" name="B1">
            </div></td>
            <td><div align="center">
              <input type="reset" value="取消添加" name="B1">
            </div></td>
          </tr>
        </table></td>
    </tr>
  </table>
  </center>
  </form>
</div>
<div align="center">
<%
fox=request("fox")
if fox="del" then
call del()
else%>
</div>
<div align="center">
  <center>
  <table border="1" cellpadding="0" cellspacing="0" style="border-width:1px; border-collapse: collapse" bordercolor="#CC0000" width="100%">
    <tr bgcolor="#BDBEDE">
      <td width="46" height="28" align="center" bgcolor="#CC0000">
		<font color="#FFFFFF">编号</font></td>
      <td width="111" height="28" align="center" bgcolor="#CC0000">
		<font color="#FFFFFF">管理帐号</font></td>
      <td width="110" height="28" align="center" bgcolor="#CC0000">
		<font color="#FFFFFF">级别</font></td>
      <td width="65" height="28" align="center" bgcolor="#CC0000">
		<font color="#FFFFFF">操作</font></td>
    </tr>
<%
dim rs,sql,i,id,fox
i=1
set rs = Server.CreateObject("ADODB.RecordSet")
sql="select * from [FOX_admin]" 
rs.open sql,conn,1,1
do while not rs.eof
%>
    <tr>
      <td width="46" height="24" align="center" bgcolor="#FAFAFA"><%=i%></td>
      <td width="111" height="24" align="center" bgcolor="#FFFFFF"><div align="left"><span class="style1"><font size="2">&nbsp;</font></span><%=rs("username")%></div></td>
      <td width="110" height="24" align="center" bgcolor="#FFFFFF"><%if rs("level")=9 then%>最高管理员<%elseif rs("level")=8 then%>分类设置员<%elseif rs("level")=7 then%>网店管理员<%elseif rs("level")=6 then%>网店审核员<%elseif rs("level")=10 then%>后台测试员<%end if%></td>
      <td width="65" height="24" align="center" bgcolor="#FAFAFA"><a href="?fox=del&id=<%=rs("id")%>">删除</a></td>
    </tr>
<%
i=i+1
rs.movenext
loop
rs.close
set rs=nothing
sub del()
id=request("id")
set rs = Server.CreateObject("ADODB.RecordSet")
sql="delete from [FOX_admin] where id="&cstr(id)
rs.open sql,conn,1,3
response.write "<font size=2>帐号删除成功!</font><br>"
response.end
end sub
set rs=nothing
end if
closedb
%>
  </table>
  </center>
</div></body></html>