📄 login_manage.asp
字号:
<%@language=vbscript codepage=936 %>
<!--#include file="conn.asp"-->
<%'!--#include file="admin.asp"--%>
<!--#include file="Inc/Function.asp"-->
<%
dim strFileName
const MaxPerPage=20
dim totalPut,CurrentPage,TotalPages
dim rs, sql
strFileName="login_manage.asp"
if request("page")<>"" then
currentPage=cint(request("page"))
else
currentPage=1
end if
Set rs=Server.CreateObject("Adodb.RecordSet")
sql="select * from login_infor order by id desc"
rs.Open sql,conn,1,1
%>
<script language=javascript>
function ConfirmDel()
{
if(confirm("确定要删除此用户吗?"))
return true;
else
return false;
}
</script>
<!-- #include file="Inc/Head.asp" -->
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="862" align="center" valign="top"><%
if rs.eof and rs.bof then
response.write "目前共有 0 个用户"
else
totalPut=rs.recordcount
if currentpage<1 then
currentpage=1
end if
if (currentpage-1)*MaxPerPage>totalput then
if (totalPut mod MaxPerPage)=0 then
currentpage= totalPut \ MaxPerPage
else
currentpage= totalPut \ MaxPerPage + 1
end if
end if
if currentPage=1 then
showContent
showpage strFileName,totalput,MaxPerPage,true,true,"个用户"
else
if (currentPage-1)*MaxPerPage<totalPut then
rs.move (currentPage-1)*MaxPerPage
dim bookmark
bookmark=rs.bookmark
showContent
showpage strFileName,totalput,MaxPerPage,true,true,"个用户"
else
currentPage=1
showContent
showpage strFileName,totalput,MaxPerPage,true,true,"个用户"
end if
end if
end if
sub showContent
dim i
i=0
%>
<table width="560" border="0" cellpadding="2" cellspacing="1" class="table_southidc">
<tr>
<td class="back_southidc" height="25"><div align="center">登录用户信息管理</div></td>
</tr>
<tr>
<td height="25"><div align="center">
<table width="560" border="0" align="center" cellpadding="0" cellspacing="2" class="border">
<tr bgcolor="#ECF5FF" class="title">
<td width="53" height="25" align="center"><strong> 序号</strong></td>
<td width="122" height="25" align="center"><strong> 用户名</strong></td>
<td width="162" height="25" align="center"><span style="font-weight: bold">登录地址</span></td>
<td width="158" height="25" align="center"><strong>登录时间</strong></td>
<td width="53" height="25" align="center"><strong> 操作</strong></td>
</tr>
<%do while not rs.EOF %>
<tr class="tdbg">
<td height="22" align="center" bgcolor="#ECF5FF"><%=rs("ID")%></td>
<td align="center" bgcolor="#ECF5FF"><%=rs("username")%></td>
<td bgcolor="#ECF5FF"><%=rs("ipaddress")%></a></td>
<td bgcolor="#ECF5FF"><%=rs("addtime")%></td>
<td align="center" bgcolor="#ECF5FF">
<a href="login_del.asp?ID=<%=rs("ID")%>" onClick="return ConfirmDel();">删除</a></td>
</tr>
<%
i=i+1
if i>=MaxPerPage then exit do
rs.movenext
loop
%>
</table>
</div></td>
</tr>
</table>
<%
end sub
%> </td>
</tr>
</table>
<!-- #include file="Inc/Foot.asp" -->
<%
rs.Close
set rs=Nothing
call CloseConn()
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -