⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 login_check.asp

📁 物流管理系统,可以用于中小企业,建立自己的内部物流管理.
💻 ASP
字号:
<%@ Language=VBScript codepage ="936" %>
<%
Response.Expires=true
Response.Buffer = true 
%>
<!--#include file="../inc/config.asp"-->
<!--#include file="../conn/dbconn1.asp" -->
<!--#include file="../inc/md5.asp"-->
<!--#include file="../inc/check.asp"-->
<!--#include file="../inc/check_input.asp"-->
<%
dim UserId,Password
dim rs,sql
UserId=Request.Form("UserId")
Password=Request.Form("Password")
Password=md5(Password)
UserId=CheckInput(UserId,"s","0")
Password=CheckInput(Password,"s","0")
	if UserId="" or Password="" then
	response.Write "<center><a href=login.asp><font color=red size=2>对不起,登陆失败,请检查您的登陆名和密码</font></a></center>"
	response.end
	end if
sql="select * from Manage_User where Username='" & UserId & "' and PassWord='" & Password & "'"
set rs= Server.CreateObject("ADODB.Recordset") 
rs.open sql,conn,1,3

if not(rs.bof and rs.eof) then
   if Password=rs("Password") then
	session("username_fyadmin")=rs("username")
	session("password")=rs("password")
	session("LastLogin")=rs("LastLogin")
	session("flag_fyadmin")=rs("flag")
	session("del")=rs("del")
	rs("LastLogin")=Now()
	rs("LastLoginIP")=Request.ServerVariables("REMOTE_ADDR")
	session.timeout=45
	rs.update
	rs.close
	set rs=nothing
	response.redirect "default.asp"
   else
	response.write"<SCRIPT language=JavaScript>alert('您输入的用户名和密码不正确。');"
	response.write"this.location.href='javascript:history.back();'</SCRIPT>" 
   end if
else
   response.write "<script LANGUAGE='javascript'>alert('您输入的用户名和密码不正确!');history.go(-1);</script>"
end if
%>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -