www.gusucode.com > 艺帆全站DIV+CSS体育用品公司网站源码 1.7.5源码程序 > i5808/admin_guanli.asp
<!--#include file="../Conn.asp" --> <!--#include file="seeion.asp"--> <% exec="select * from i5808" set rs=server.createobject("adodb.recordset") rs.open exec,conn,1,1 if rs.eof then response.Write "<div style=""padding:10px"">暂无记录!</a>" response.End() else rs.PageSize =10 iCount=rs.RecordCount iPageSize=rs.PageSize maxpage=rs.PageCount page=request("page") if Not IsNumeric(page) or page="" then page=1 else page=cint(page) end if if page<1 then page=1 elseif page>maxpage then page=maxpage end if rs.AbsolutePage=Page if page=maxpage then x=iCount-(maxpage-1)*iPageSize else x=iPageSize end if end if %> <!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" /> <title>管理员管理</title> <link href="images/style.css" type="text/css" rel="stylesheet" /> </head> <body> <table width="99%" border="0" align="center" cellpadding="10" cellspacing="1" > <tr> <td bgcolor="#F7F7F7"><div align="left"><strong>管理员管理</strong><span class="text2"></span> <a href="admin_add.asp" style="color:#F00">添加管理员</a></div></td> </tr> <tr> <td bgcolor="#FFFFFF"><table width="100%" border="0" cellspacing="5" cellpadding="0"> <tr bgcolor="#CCCCCC"> <td width="23%" align="center">ID</td> <td width="36%" align="center">管理员用户名</td> <td width="41%" align="center">操作</td> </tr> <% dim i i=1 do while not rs.eof %> <tr> <td align="center"><%=rs("id")%></td> <td align="center"><%=rs("admin")%></td> <td align="center"><input type="button" name="Submit3" value="修改" onclick="window.location.href='xiugaipassword.asp?id=<%=rs("id")%>' " class="btn"/> <input type="button" name="Submit" value="删除" onclick="javascript:if(confirm('确定删除?删除后不可恢复!')){window.location.href='?id=<%=rs("id")%>&del=ok';}else{history.go(0);}" class="btn"/> </td> <% if i mod 1 =0 then response.Write "<tr>" end if i=i+1 rs.movenext loop %> </tr> </table> </td> </tr> </table> </body> </html> <% if request("del")="ok" then set rs=server.createobject("adodb.recordset") id=Request.QueryString("id") sql="select * from i5808 where id="&id rs.open sql,conn,2,3 rs.delete rs.update Response.Write "<script>alert('当前管理员删除成功!');window.location.href='admin_guanli.asp';</script>" end if %>