📄 saverification.asp
字号:
<!--#include file="../include/conn2.asp"-->
<!--#include file="md5.asp"-->
<%
sub ShowMsg(msg)
msg=server.URLEncode(msg) '将字符串编码,以便做参数传递
response.Redirect("salogin.asp?msg=" + msg)
end sub
dim user,pass,yanzheng
user = request("saname")
pass = request("saps")
pass = MD5(pass)
yanzheng = request("sapsv")
set rs = server.CreateObject("ADODB.RecordSet")
strSQL="select * from admin where saname='" & user &"'"
rs.open strSQL,conn,1,1
if rs.eof then
ShowMsg("用户名或密码不正确!")
end if
if trim(rs("sapass"))<>pass then
ShowMsg("用户名或密码不正确!")
elseif yanzheng <> "fixty" then ShowMsg("验证码不正确!")
end if
Session("LoginName")=rs("saname") '账号
Session("PassWord")=rs("sapass") '密码
Session("ID")=rs("ID")
rs.close
set rs = nothing
conn.close
set conn = nothing
response.Redirect("default.asp")
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -