📄 editadmin.asp
字号:
<!--#include file="conn.asp" -->
<%if session("user")<>"" and session("pwd")<>"" then%>
<%
set rs=server.createobject("adodb.recordset")
sql="select * from admin"
rs.open sql,conn,1,3
if session("pwd")=rs("pwd") then
If Request("edit")="ok" Then
user=Request.Form("user")
pwd=request.form("pwd")
rs("user")=user
rs("pwd")=pwd
rs.update
session("user")=rs("user")
session("pwd")=rs("pwd")
End If
End If
%>
<html>
<head>
<title>修改资料</title>
<link href="aaa.css" rel="stylesheet" type="text/css">
</head>
<body>
<%if request("edit")="ok" then%>
<table border="0" width="100%" cellspacing="0" cellpadding="0" height="100%">
<tr>
<td width="100%" height="50">
<p align="center"><font color="#FF0000">修改资料成功!</font><br>
<br>
2 秒后自动<a href="index.asp">返回留言本首页</a>....</td>
</tr>
</table>
<meta http-equiv="refresh" content="2;URL=index.asp">
<%else%>
<div align="center"><font size="5">修改站长管理用户名和密码</font><br>
</div>
<form name="form1" method="post" action="editadmin.asp?edit=ok">
<table width="350" border="0" align="center" cellpadding="8" cellspacing="0" class="tbline">
<tr>
<td width="85"><div align="right">用户名:</div></td>
<td width="381"><input name="user" type="text" id="user" value="<%=rs("user")%>" size="20" maxlength="15">
</td>
</tr>
<tr>
<td valign="top"> <div align="right">密码:</div></td>
<td><input name="pwd" type="password" id="pwd" value="<%=rs("user")%>" size="20" maxlength="15">
</td>
</tr>
<tr>
<td colspan="2"><div align="center">
<input type="submit" name="Submit" value="修改">
<input type="reset" name="Submit2" value="重写">
</div></td>
</tr>
</table>
</form>
<div align="center"><br>
<a href="index.asp">返回>></a> </div>
</body>
</html>
<% rs.close
Set rs = nothing
Conn.Close
Set conn = nothing
%>
<% End If %>
<% End If %>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -