📄 chklogin.asp
字号:
<%response.buffer=true%>
<!--#include file="conn.asp"-->
<!--#include file="inc/config.asp"-->
<!--#include file="../webconfig.asp"-->
<!--#include file="../fuction.asp"-->
<html>
<head>
<title><%=bbsname%>-论坛中心</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="SHORTCUT ICON" href="/shortcut.ico">
<meta name="generator" content="snsn-shop">
<meta name=keywords content="<%=webgjz%>">
<meta name="description" content="<%=webmx%>">
<meta name="MSSmartTagsPreventParsing" content="TRUE">
<meta http-equiv="MSThemeCompatible" content="Yes">
<link href="/css.css" rel="stylesheet" type="text/css">
<!--#include file="../webtop.asp"-->
<table width="940" align="center" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="6" colspan="3"></td>
</tr>
<tr>
<td width="17"><img src="/img/index_1.gif" width="15" height="16"></td>
<td valign="bottom">您现在的位置是:<a href="<%=weburl%>"><%=webname%></a> -> <span class="table-shangxia"><span class="b14"> <a href=index.asp><%=bbsname%></a> → 用户登陆</span></span></td>
<td valign="bottom"> </td>
</tr>
<tr>
<td height="6" colspan="3"></td>
</tr>
</table>
<!--#include file="top.asp"-->
<!--#include file="../md5.asp"-->
<table width="760" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td valign="top">
<p> </p>
<table width="747" border="0" align="center" cellpadding="0" cellspacing="0">
<form method='POST' name='login' action='chklogin.asp'>
<tr>
<td height='26' align='center' width="745">
<%comeurl=Replace(Request.Form("comeurl"),"'","''")
if comeurl="" then
comeurl=Request.ServerVariables("HTTP_REFERER")
end if
username=nosql(trim(Request.Form("username")))
password=md5(Request.Form("password"))
cookies=int(request.form("cookies"))
set rs=server.CreateObject("adodb.recordset")
rs.Open "select * from [shop_user] where username='"&username&"' and userpassword='"&password&"' " ,conn,1,3
if rs.eof and rs.bof then
response.write"你的用户名或密码错误<br><a href='javascript:history.go(-1)'>返回重新登陆</a>"
response.end
elseif password<>rs("userpassword") then
response.write"你的用户名或密码错误<br><a href='javascript:history.go(-1)'>返回重新登陆</a>"
response.end
else
name=rs("username")
pass=rs("userpassword")
manbid=rs("manbid")
pic=rs("pic")
session("username")=name
session("userpassword")=pass
session("manbid")=manbid
session("pic")=pic
Response.Cookies("snsn")("Cookies")=Cookies
if int(cookies)<>0 then
Response.Cookies("snsn").Expires=date+int(cookies)
end if
session("reglx")=rs("reglx")
session("jifen")=rs("jifen")
session("jiaoyijine")=rs("jiaoyijine")
rs("lastlogin")=now()
rs("logins")=rs("logins")+1
rs("userlastip")=Request.ServerVariables("REMOTE_ADDR")
rs.Update
rs.Close
set rs=nothing
response.write"登陆成功!<a href='index.asp'>进入论坛首页</a><br><meta http-equiv=refresh content=3;url="&comeurl&"><a href='"&comeurl&"'>"&comeurl&"</a>"
end if
riqi=now()
conn.execute("update shop_user set zjdlsj='"&riqi&"' where username='"&username&"'")
Set rs1 = Server.CreateObject("ADODB.Recordset")
SQL1= "Select * from online where name='"&name&"'"
rs1.open sql1, conn, 1, 3
if rs1.eof then
rs1.AddNew
rs1("name")=name
rs1("ip")=request.servervariables("remote_addr")
rs1("ltime")=now()
rs1.Update
else
end if
%>
</td>
</tr></form>
</table>
<p> </p></td>
</tr>
</table></td>
</tr>
</table>
<!--#include file="../copyright.asp"-->
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -