📄 usermanage.asp
字号:
<!--#include file = include.asp-->
<%
if request.form("operation")="DEL" then
Num=request.form("ID").count
for i=1 to num
conn.execute("delete from UserManage where ID="&request.form("ID")(i))
next
end if
set CheckUser = server.createobject("adodb.recordset")
sql = "select * from UserManage where UserName='"&Name&"' and password='"&PassWord&"' "
CheckUser.open sql,conn,1,1
Purview=CheckUser("purview")
select case Purview
case "管理员"
set rs=Server.CreateObject("adodb.recordset")
sql="select * from UserManage order by id desc"
rs.open sql,conn,1,1
AddUser="<b><a href=UserAdd.Asp>添加用户</a></b>"
case "总编辑"
response.redirect"UserSetModify.asp"
case "录入员"
if CheckUser("ModPas") then
response.redirect"UserSetModify.asp"
else
response.redirect"error.asp?msg=修改密码"
end if
end select
%>
<body background="images/BLogo.gif">
<form method=post action="">
<table width="466" border="0" cellspacing="1" cellpadding="0" align="center" bgcolor="#4397c5">
<tr bgcolor="#FFFFFF">
<td colspan="3" width="100%" height="25">
<!--#include file = topMenu.htm--></td>
</tr>
<tr bgcolor="#FFFFFF" valign="middle" align="center">
<td height="2" colspan="3" background="images/BLogo.gif">
<table width="100%" border="0" cellspacing="1" cellpadding="0" bgcolor="#F5F5F5">
<tr bgcolor="#FFFFFF">
<td height=20 width="17%" align=center onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor='';>用户名</td>
<td height=20 width="18%" align=center onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor='';>密码</td>
<td height=20 width="15%" align=center onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor='';>类型</td>
<td height=20 width="27%" align=center onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor='';>添加日期</td>
<td height=20 width="12%" align=center onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor='';>修改</td>
<td height=20 width="11%" align=center onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor='';>删除</td>
</tr>
<%
for i=1 to rs.recordcount
%>
<tr bgcolor="#FFFFFF">
<td height=20 width="17%" align=center onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor='';><%=rs("UserName")%></td>
<td height=20 width="18%" align=center onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor='';>*******</td>
<td height=20 width="15%" align=center onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor='';><%=rs("Purview")%></td>
<td height=20 align=center onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor=''; width="27%"><%=rs("Date")%></td>
<td height=20 align=center onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor=''; width="12%"><a href="UserModify.asp?ID=<%=rs("ID")%>&UserType=<%=rs("Purview")%>">修改</a></td>
<td height=20 width="11%" align=center onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor='';>
<input type="checkbox" name=ID value="<%=rs("ID")%>">
</td>
</tr>
<%
rs.movenext
next
%>
<tr bgcolor="#FFFFFF">
<td height=20 colspan=3 onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor='';><%=adduser%></td>
<td height=20 align=right onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor='';> </td>
<td height=20 colspan=2 align=right onMouseOver=this.style.backgroundColor='#FAFBFC'; this.style.cursor='hand'; onMouseOut=this.style.backgroundColor='';>
<input type=hidden value=DEL name=operation>
<input type=submit value="删除" onClick="return Del()" name="submit">
</td>
</tr>
</table>
</td>
</tr>
</table>
</form>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -