<!--#include file="System/DBconn.asp"-->
<!--#include file="System/char.asp"-->
<!--#include file="md5.asp"-->
<%
dim uid ,upwd,rs,sqltext,lastlogin
uid=checkStr(trim(Request.Form("userid")))
upwd=checkStr(trim(Request.Form("password")))
set rs=server.createobject("adodb.recordset")
sqltext="select adspass,popedom from Adsuper where admintype=0 and adsname='" & uid & "'"
rs.open sqltext,conn,1,1
if rs.eof and rs.bof then
response.write"<SCRIPT language=JavaScript>alert('您输入的用户名不正确。');"
response.write"this.location.href='javascript:history.back();'</SCRIPT>"
rs.close
set rs=nothing
else
if upwd<>rs("adspass") then
response.write"<SCRIPT language=JavaScript>alert('您输入的密码不正确。');"
response.write"this.location.href='javascript:history.back();'</SCRIPT>"
rs.close
set rs=nothing
else
session("adsname")=uid
session("popedom")=rs("popedom")
session.timeout=45
lastlogin=now()
conn.execute("update Adsuper set Lastlogintime='"&lastlogin&"',LastLoginIp='"&Request.ServerVariables("REMOTE_ADDR")&"' where adsname='"&uid&"'")
rs.close
set rs=nothing
response.redirect "Index.asp"
end if
end if
%>
用密码登陆的时候出现密码错误
用加密后的密码却能登陆!是不是这里代码有什么问题
请高手指教!谢谢