📄 admin_user.asp
字号:
<!--#include file="connect.asp" -->
<!--#include file="..\include\md5.asp" -->
<!--#include file="..\include\nosqlin.asp" -->
<%
if request.Cookies("admin") = "" then
user = request.form("username")
'password = md5(request.form("pass"))
password = request.form("pass")
'response.write user &"/"&password
'response.end
strSQL = "select * from information where user = '"&user&"' and password = '"&password&"'"
'response.write "strSQL:"&strSQL
set rs = objCnn.Execute(strSQL)
'response.end
if rs.eof then
msg = "用户名或密码错误!"
%>
<Script language=VBScript>
msgbox "<%=msg%>"
history.back
</Script>
<%
response.end
else
response.Cookies("admin") = rs("admin")
response.Cookies("user") = user
response.Cookies("password") = password
end if
else
user = request.Cookies("user")
password = request.Cookies("password")
strSQL = "select * from information where user = '"&user&"'"
set rs = objCnn.Execute(strSQL)
end if
%>
<html>
<head>
<BASE onmouseover=window.status="<%=Unit%>个人主页空间——您理想的网上家园!";return true>
<meta http-equiv="Content-Language" content="en-us">
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title><%=Unit%>>><%=softname%>>>管理员专用</title>
<style type="text/css">
a:link {
color: #333333;text-decoration:none
}
a:visited {
color: #666666;text-decoration:none
}
a:active {
color: #999999;text-decoration:none
}
A:hover {
color: #FF0000;text-decoration:underline
}
-->
</style>
<SCRIPT LANGUAGE=javascript>
<!--
function openurl(url)
{
window.open(url,"公告管理","Menubar=no,directories=no,status=no,scrollbars=yes,resizable=no,Width=600,Height=400");
}
function openurl1(url)
{
window.open(url,"清理图片","Menubar=no,directories=no,status=no,scrollbars=yes,resizable=no,Width=60,Height=40");
}
-->
</Script>
</head>
<BODY bgcolor="#E1EBF4" style="font-size: 9pt">
<!--#include file="head.asp" -->
<!--#include file="NavBar.Asp" -->
<%select Case request.Cookies("admin")%>
<%case 1%>
<table border="0" width="750" style="border: 1 solid #000000" cellspacing="0" cellpadding="4" height="70%">
<tr>
<td width="100%">
<div align="center">
<table border="0" width="96%" height="100%" style="font-size: 9pt">
<tr>
<td width="16%" style="border-right: 1 solid #C0C0C0" valign="top">
<table border="0" width="100%" style="font-size: 9pt">
<tr>
<td width="100%"><b>管理员</b><b>:<%=rs("username")%></b></td>
</tr>
<tr>
<td width="100%"> ◆ <a href="admin_mod.asp"> 修改信息</a></td>
</tr>
<tr>
<td width="100%"> ◆ <a href="quit.asp">退出</a></td>
</tr>
<tr>
<td width="100%"><b> </b></td>
</tr>
<tr>
<td width="100%"><b>管理功能</b></td>
</tr>
<tr>
<td width="100%"> ◆ 用户查看</td>
</tr>
<tr>
<td width="100%"> ◆ <a href="admin_check.asp"> 用户审核/管理</a></td>
</tr>
<tr>
<td width="100%"> ◆ <a href="shenqing.asp"> 添加用户</a></td>
</tr>
<tr>
<td width="100%"> ◆ <a href="javascript:openurl('affiche_manage.asp');">公告管理</a></td>
</tr>
<tr>
<td width="100%"> ◆ <a href="javascript:openurl1('P_Clear.asp');">清理图片</a></td>
</tr>
</table>
</td>
<center>
<td width="84%" valign="top" style="font-size: 9pt">
<p align="center">
<%
dim rs1
CurrentPage=request("page")
if CurrentPage="" then CurrentPage=1
set rs1=server.createobject("adodb.recordset")
strSQL = "select * from information where admin > 1 order by user"
rs1.open strSQL,objCnn,1,3
MaxPerPage=20
RS1.PageSize= MaxPerPage
if not isempty(request("page")) and request("page")<>"" then
currentPage=cint(request("page"))
else
currentPage=1
end if
totalPut = Rs1.recordcount
if totalPut > 0 then
if currentpage < 1 then currentpage=1
RS1.AbsolutePage = currentpage
end if
%>
<b><font color="#008080"><br>
用户管理</font></b><br>
<div align="right" style="width: 590; height: 63">
<table border="1" width="100%" style="font-size: 9pt; border-style: solid; border-width: 0" cellspacing="0" cellpadding="2" bordercolorlight="#C0C0C0" bordercolordark="#FFFFFF">
<tr height="26">
<td align="center"><b>用户名</b></td>
<td align="center"><b>姓名</b></td>
<td align="center"><b>呢称</b></td>
<td align="center"><b>E-Mail</b></td>
<td align="center"><b>电话</b></td>
<td align="center"><b>主页</b></td>
<td align="center"><b>注册时间</b></td>
<td align="center"><b>状态</b></td>
</tr>
<%for i=1 to MaxPerPage%>
<tr <%if not rs1("check") then%> bgcolor="#FEF3F1"<%end if%> height=26>
<td> <%=rs1("user")%></td>
<td><%=rs1("username")%></td>
<td><%=rs1("wname")%></td>
<td align="center"><a href='mailto:<%=rs1("email")%>'><img border="0" src="../images/MAIL.GIF"></a></td>
<td><%if rs1("tel")<>"" then%><%=rs1("tel")%><%else%><%=rs1("tel1")%><%end if%></td>
<td><%=rs1("wwwname")%></td>
<td align="center"><%=rs1("CreateDate")%></td>
<td align="center"><%if rs1("check") then%>激活<%else%><font color=red>锁定</font><%end if%></td>
</tr>
<%
rs1.movenext
if rs1.eof then exit for
next
%>
</table>
<BR>
</div>
<%
showpage rs1.recordcount,MaxPerPage,"admin_user.asp"
%>
</td>
</tr>
</table>
</center>
</div>
</td></tr></table>
<%case 2%>
<%case 3%>
<div align="center">
<center>
<table border="0" width="750" style="border: 1 solid #000000" cellspacing="0" cellpadding="4" height="70%">
<tr>
<td width="100%">
<div align="center">
<center>
<table border="0" width="80%" style="font-size: 9pt" height="100%">
<tr>
<td width="25%" valign="top" height="100%" style="border-right: 1 solid #C0C0C0">
<table border="0" width="100%" style="font-size: 9pt">
<tr>
<td width="100%">欢迎<font color='red'><b><%=rs("username")%></b></font>登录</td>
</tr>
<tr>
<td width="100%">您可以在此修改您的<br><font color="#008080">网站信息</font>和<font color="#008080">登录密码</font></td>
</tr>
<tr>
<td width="100%"></td>
</tr>
<tr>
<td width="100%"><a href="admin_mod_user.asp?info">修改网站信息</a></td>
</tr>
<tr>
<td width="100%"><a href="admin_mod_user.asp?pass">修改登录密码和呢称</a></td>
</tr>
<tr>
<td width="100%"><a href="ftp://<%=rs("user")%>@<%=servername%>:<%=serverport%>/" target="_blank">FTP登录</a></td>
</tr>
<tr>
<td width="100%"></td>
</tr>
<tr>
<td width="100%"><a href="hlp.asp" target="_blank">帮助信息</a></td>
</tr>
<tr>
<td width="100%"><a href="quit.asp">退出</a></td>
</tr>
</table>
</td>
<td width="75%" height="100%" valign="top">
<div align="center">
<center><table width="80%"><tr><td>
<fieldset>
<legend><font size="2" color="#F89A7E"><b>您的个人信息</b></font></legend>
<table border="0" width="100%" style="font-size: 9pt">
<tr>
<td width="31%" align="right">姓名:</td>
<td width="69%"><%=rs("username")%></td>
</tr>
<tr>
<td width="31%" align="right">部门/班级:</td>
<td width="69%"><%=rs("userclass")%></td>
</tr>
<tr>
<td width="31%" align="right">联系电话:</td>
<td width="69%"><%=rs("tel")%></td>
</tr>
<tr>
<td width="21%" align="right">电子信箱:</td>
<td width="59%"><%=rs("email")%></td>
</tr>
<tr>
<td width="31%" align="right">住址:</td>
<td width="69%"><%=rs("adress")%></td>
</tr>
<tr>
<td width="31%" align="right"></td>
<td width="69%"></td>
</tr>
</table>
</fieldset></td></tr></table>
<table width="80%"><tr><td>
<fieldset>
<legend><font size="2" color="#F89A7E"><b>网站信息</b></font></legend>
<table border="0" width="100%" style="font-size: 9pt">
<tr>
<td width="31%" align="right" valign="top">用户名:</td>
<td width="69%" valign="top"><%=rs("user")%></td>
</tr>
<tr>
<td width="31%" align="right" valign="top">呢称:</td>
<td width="69%" valign="top"><%=rs("wname")%></td>
</tr>
<tr>
<td width="31%" align="right" valign="top">网站名称:</td>
<td width="69%" valign="top"><%=rs("wwwname")%></td>
</tr>
<tr>
<td width="31%" align="right" valign="top">网站功能:</td>
<td width="69%" valign="top"><%=rs("wwwfunction")%></td>
</tr>
<tr>
<td width="31%" align="right" valign="top">LOGO图片:</td>
<td width="69%" valign="top"><%if rs("pic")<>"" then%><img border="0" src="..\uppic\<%=rs("pic")%>" width="200" height="30"><%else%><%="没有LOGO图片"%><%end if%></td>
</tr>
</table>
</fieldset></td></tr></table>
</center>
</div>
</td>
</tr>
</table>
</center>
</table>
</center>
</div>
<%end select%>
<!--#include file="..\food.asp" -->
</body>
<%
function showpage(totalnumber,maxperpage,filename)
dim n
if totalnumber mod maxperpage=0 then
n= totalnumber \ maxperpage
else
n= totalnumber \ maxperpage+1
end if
response.write "<table cellspacing=1 width='100%' border=0 colspan='4' style='font-size: 9pt'><tr><td align=right> "
if CurrentPage<2 then
response.write "共 "&totalnumber&" 位用户 首页 上一页 "
else
response.write ""&totalnumber&"位 <a href="&filename&"?page=1"">首页</a> "
response.write "<a href="&filename&"?page="&CurrentPage-1&">上一页</a> "
end if
if n-currentpage<1 then
response.write "下一页 尾页"
else
response.write "<a href="&filename&"?page="&(CurrentPage+1)&">"
response.write "下一页</a> <a href="&filename&"?page="&n&">尾页</a>"
end if
response.write " 页次:<strong><font color=red>"&CurrentPage&"</font>/"&n&"</strong>页 "
response.write " <b>"&maxperpage&"</b>位用户/页 </td></tr></table>"
end function
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -