📄 index.asp
字号:
<%Response.Buffer=True%>
<!--#Include file="odbc_connection.asp"-->
<html>
<head>
<title>办公自动化系统</title>
</head>
<body background="68240_6121.jpg" bgproperties="fixed">
<h2 align="center"><i><b><font size="7">办公自动化系统登陆界面</font></b></i></h2>
<center>
<form method="post" action="">
<table border="0" width="803" bgcolor="#E6E6E6">
<tr>
<td width="111"><b>姓名</b>:</td><td width="176"><input type="text" name="name" size="20" >**</td>
</tr>
<tr>
<td width="111"><b>密码</b>:</td><td width="176"><input type="password" name="password" size="20">**</td>
</tr><tr>
<td width="111"></td><td width="176"><input type="submit" value=" 确 定 "><input type="reset" value=" 重 填 "> </td><td width="176"><a href="add_form.htm">注册会员</a> </td><td width="314"></td>
</tr>
<td width="111">
<table>
</form>
</center>
<%
'如果没有输入姓名,就不执行下列语句
If Trim(Request("name"))<>"" Then
Dim rs,strSql
strSql ="Select * From users Where name='" & Request("name") & "' And password='" & Request("password") & "'"
Set rs=db.Execute(strSql)
'查找匹配的记录,如果非空,就表示找到了。则引导至update_form.asp
If Not rs.Bof And Not rs.Eof Then
'这里用Session传递记录的id号,而不是在文件后跟参数,是为了安全考虑
Session("id")=rs("id")
Response.Redirect "shouye.htm"
Else
Response.Write "对不起,密码不正确,请重新输入"
End If
End If
%>
</table>
</body>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -