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

📄 login_admin.asp

📁 大概说明: 一:登陆后台前请先smszzun_admin,找到IP_report.asp这个文件,把里面的IP地址更换成你的本机IP 如果IP不符合则不能打开后台页面,这是为了数据安全
💻 ASP
📖 第 1 页 / 共 2 页
字号:
<!--#include file="IP_report.asp"-->
<!--#include file="conn_admin.asp"-->
<%
JyDownLoginTitle="短信后台集成管理系统"
if request("JyDownType")="logout" then
JyDownLoginTitle="退出登陆"
JyDownLoginMgs="成功:退出登陆成功!"
if Session("selviceAdminName")<>"" then
Session("selviceAdminName")  =""
Session("selviceAdminDj")=""
response.cookies("JyDownUserSoftUrl")=""
end if
if request.cookies("JyDownUserName")<>"" then
response.cookies("JyDownUserName")  =""
response.cookies("JyDownUserDj")=""
end if
elseif request("JyDownType")="login" then
server_vv=len(Request.ServerVariables("SERVER_NAME"))
server_v1=left(Cstr(Request.ServerVariables("HTTP_REFERER")),server_vv)
server_v2=left(Cstr("http://"&Request.ServerVariables("SERVER_NAME")),server_vv)
if server_v1<>server_v2 or server_v1="" or server_v1="" then
response.write("<script>alert('错误:禁止从站点外部提交数据!.')</script>")
response.end
end if
  if request.form("user")<>"" and request.form("pwd")<>"" then
user=replace(request("user")," ","+++ close")
  pwd=replace(request("pwd")," ","+++ close")
verifycode=replace(trim(Request("verifycode")),"'","")
  set rs=server.createobject("adodb.recordset")
  rs.open "select * from UserInfo where user='"&user&"' and pwd='"&pwd&"'",conn,1,1
  thesoft=Request.ServerVariables("HTTP_USER_AGENT")
  if instr(thesoft,"Windows NT 5.0") then
	vOS="Win 2000"
elseif instr(thesoft,"Windows NT 5.1") then
	vOs="Win XP"
elseif instr(thesoft,"Windows NT") then
	vOs="Win NT"
elseif instr(thesoft,"Windows 9") then
	vOs="Win 9x"
elseif instr(thesoft,"unix") or instr(thesoft,"linux") or instr(thesoft,"SunOS") or instr(thesoft,"BSD") then
	vOs="类Unix"
elseif instr(thesoft,"Mac") then
	vOs="Mac"
else
	vOs="Other"
end if
  if not rs.eof then
    if pwd=rs("pwd") and user=rs("user") then
      JyDownDj=rs("dj")
      if JyDownDj=0 or JyDownDj=1 or JyDownDj=2 or JyDownDj=3 then
        if rs("lock")=1 then
          JyDownLoginMgs="错误:帐号 "&user&" 已被锁定,你不能登陆!"
        else
          JyDownLoginMgs="成功:帐号 "&user&" 登录成功!"
          if JyDownDj=0 then SF="普通会员"
          if JyDownDj=1 then SF="高级会员"
          if JyDownDj=2 then SF="系统管理员"
          if JyDownDj=3 then SF="站长"
          response.cookies("JyDownUserName")=rs("user")
          response.cookies("JyDownUserDj")=rs("dj")
          if JyDownDj=2 or JyDownDj=3 then
                      if rs("softurl")<>"" then
            response.cookies("JyDownUserSoftUrl")=rs("softurl")
            end if
            Session("selviceAdminName")=rs("user")
            Session("selviceAdminDj")=rs("dj")
            Session("selviceAdminAdmin")=rs("admin")
                                UserId = rs("id")
  set rs1=Server.Createobject("adodb.recordset")
   sql1="Select * from Log"
   rs1.open sql1,conn,3,3
   rs1.addnew
   rs1("User")=rs("user")
   rs1("LoginIP")=request.ServerVariables("Remote_Addr")
   rs1("OS")=vOS
   rs1.update
   rs1.close
          end if
        end if
      else
        JyDownLoginMgs="错误:你的用户等级错误,不能登陆,请与站长联系!"
   set rs1=Server.Createobject("adodb.recordset")
   sql1="Select * from Log"
   rs1.open sql1,conn,3,3
   rs1.addnew
   rs1("User")=Request.Form("User")
   rs1("LoginIP")=request.ServerVariables("Remote_Addr")
   rs1("OS")=vOS
   rs1("ErrorPas")=Request.Form("pwd")
   rs1("Result")="Error"
   rs1.update
   rs1.close
      end if
    else
      JyDownLoginMgs="错误:用户名或密码错误!"
   set rs1=Server.Createobject("adodb.recordset")
   sql1="Select * from Log"
   rs1.open sql1,conn,3,3
   rs1.addnew
   rs1("User")=Request.Form("User")
   rs1("LoginIP")=request.ServerVariables("Remote_Addr")
   rs1("OS")=vOS
   rs1("ErrorPas")=Request.Form("pwd")
   rs1("Result")="Error"
   rs1.update
   rs1.close
    end if
  else
    JyDownLoginMgs="错误:用户名或密码错误!"
   set rs1=Server.Createobject("adodb.recordset")
   sql1="Select * from Log"
   rs1.open sql1,conn,3,3
   rs1.addnew
   rs1("User")=Request.Form("User")
   rs1("LoginIP")=request.ServerVariables("Remote_Addr")
   rs1("OS")=vOS
   rs1("ErrorPas")=Request.Form("pwd")
   rs1("Result")="Error"
   rs1.update
   rs1.close
  end if
  rs.close
  set rs=nothing
  conn.close
  set conn=nothing
  else
    JyDownLoginMgs="错误:用户名和密码都不能为空!"
  end if
'if  verifycode<>CStr(session("CheckCode"))  then 
'esponse.write"<script>alert(""验证码不正确,请刷新后重新登陆"");location.href=""login_admin.asp"";</script>"
'Response.end
'end if
end if
%>
<html>
<head>
<title><%=JyDownLoginTitle%></title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<style>
td{font-size:9pt} 
body{font-size:9pt} 

a:link          { color: #0033CC; text-decoration: none }
a:visited       { color: #0033CC; text-decoration: none }
a:active        { color: #FF0000; text-decoration: none }
a:hover         { color: #000000; text-decoration: underline}
</style>
</head>
<body topmargin="10" leftmargin="0" bgcolor="#FFFFFF" text="#000000">
<form method="post" action="login_admin.asp?JyDownType=login" target="_top">
<div align="center">
<center>
      <table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" width="600">
        <%if JyDownLoginMgs<>"" then%>
        <tr> 
          <td width="100%" bgcolor="#FFFFFF"> 
            <p align="left">&nbsp; 
            <table align=center border=0 cellpadding=0 cellspacing=0 width=600>
              <tbody> 
              <tr> 
                <td width=207> </td>
                <td width=11></td>
                <td width="537" align=right valign=bottom> 
                  <div id=topnav>&nbsp;<font color="#FFFFFF">|</font></div>
                </td>
              </tr>
              </tbody>
            </table>
            <table width="95%" border="0" cellspacing="0" cellpadding="0">
              <tr> 

⌨️ 快捷键说明

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