<!DOCTYPE html>
<!-- 
'========================================================================================
' 文 件 名: m_admin_login.asp
' 版    本: 岭峰网行业专用留言系统3.10.0 (LFMessS 2020 - 3.10.0.F Build 200604)
' 说    明: 移动端管理员登陆页面 | 请小心修改为自己的风格
' 文件日期: 2020-06-04
' 设 计 者: 疾风之狼
'========================================================================================
' 郑州文达岭峰网络科技有限公司.
'========================================================================================
' Copyright (C) 2001-2020 岭峰网. All rights reserved.
' 网    站: http://www.lfmesss.com
' 电子邮件: support@lfmesss.com
' 联系ＱＱ: 85112407
'========================================================================================
-->
<%@ language="vbscript" codepage="936" %>
<%flg = "manok"%>
<!-- #include file="../common/m_sub_inc.asp" -->
<!-- #include file="../common/commfun.asp" -->
<!-- #include file="../common/ip_purview.asp" -->
<!-- #include file="../common/checkru.asp" -->
<!-- #include file="../common/md5_32.asp" -->
<%
IF Session("LingFengNet_MS_admin") = "ok" and Session("LingFengNet_MS_admin_flg") = "3" Then Response.Redirect "m_admin_stlist"&Get_Suffix() 
IF Session("LingFengNet_MS_admin") = "ok" and ( Session("LingFengNet_MS_admin_flg") = "2" or Session("LingFengNet_MS_admin_flg") = "1" ) Then Response.Redirect "m_admin_stlist"&Get_Suffix()
IF Session("DatabaseErr") <> "ok_now" Then
%>
<!-- #include file="../common/connect.asp" -->
<%
End IF	 
IF Request("set") = "ok" Then
	adminname = Trim(Request.Form("LingFengNet_MS_adminname"))
	adminpass = Trim(Request.Form("LingFengNet_MS_adminpass"))
	IF Len(adminpass) <> 32 Then
		adminpass = LFW_md5_32_pass(adminpass)
	End IF
	reg = Fix(Trim(Request.Form("reg")))
	
	IF adminname = "" or adminpass = "" Then
		Response.Write "<meta http-equiv=Content-Type content=text/html;charset="& LingFengNet_MS_language_meta_mes_1 &"><script>" 
		Response.Write "alert('"& LingFengNet_MS_language_Warning_login_1 &"');" 
		Response.Write "history.go(-1);" 
		Response.Write "</script>" 
		Response.End
	End IF
	
	IF Not IsNumeric(reg) Then
		Response.Write "<meta http-equiv=Content-Type content=text/html;charset="& LingFengNet_MS_language_meta_mes_1 &"><script>" 
		Response.Write "alert('"& LingFengNet_MS_language_Warning_login_2 &"');" 
		Response.Write "history.go(-1);" 
		Response.Write "</script>" 
		Response.End
	End IF
	
	IF CLng(reg) <> Clng(Session("LFW_Safecode")) Then
		Response.Write "<meta http-equiv=Content-Type content=text/html;charset="& LingFengNet_MS_language_meta_mes_1 &"><script>" 
		Response.Write "alert('"& LingFengNet_MS_language_Warning_login_2 &"');" 
		Response.Write "history.go(-1);" 
		Response.Write "</script>" 
		Response.End
	End IF
	
	IF Instr(LingFengNet_MS_adminname,adminname) = 0 or Instr(LingFengNet_MS_adminpass,adminpass) = 0 Then
		Response.Write "<meta http-equiv=Content-Type content=text/html;charset="& LingFengNet_MS_language_meta_mes_1 &"><script>" 
		Response.Write "alert('"& LingFengNet_MS_language_Warning_login_2 &"');" 
		Response.Write "history.go(-1);" 
		Response.Write "</script>" 
		Response.End
	End IF
	
	IF Instr(LingFengNet_MS_adminname, "|") = 0 or Instr(LingFengNet_MS_adminpass, "|") = 0 Then
		IF LingFengNet_MS_adminname = adminname and LingFengNet_MS_adminpass = adminpass Then
			Session("LingFengNet_MS_admin") = "ok"
			Session("LingFengNet_MS_admin_flg") = LingFengNet_MS_adminflg
			Session("LingFengNet_MS_admin_flg_adminname") = LingFengNet_MS_adminname
			Session("LingFengNet_MS_admin_flg_login") = LingFengNet_MS_language_messdef_mesok_re_admin_4 & LingFengNet_MS_adminpublicname
		End IF	
	Else		
		nameReturn = Split(LingFengNet_MS_adminname, "|")
		passReturn = Split(LingFengNet_MS_adminpass, "|")
		flgReturn = Split(LingFengNet_MS_adminflg, "|")
		publicnameReturn = Split(LingFengNet_MS_adminpublicname, "|")
		For i = LBound(nameReturn) To UBound(nameReturn)
			IF Trim(nameReturn(i)) = adminname and Trim(passReturn(i)) = adminpass Then 
				Session("LingFengNet_MS_admin") = "ok"
				Session("LingFengNet_MS_admin_flg") = flgReturn(i)
				Session("LingFengNet_MS_admin_flg_adminname") = Trim(nameReturn(i))
				Session("LingFengNet_MS_admin_flg_login") = LingFengNet_MS_language_messdef_mesok_re_admin_4 & Trim(publicnameReturn(i))
				Exit For
			End IF
		Next 
	End IF
	
	IF Session("LingFengNet_MS_admin") = "ok" Then
		'Session("LingFengNet_MS_admin")="ok"
		'Session("LingFengNet_MS_admin_flg")=LingFengNet_MS_adminflg
		'Session("LingFengNet_MS_admin_flg_login")=LingFengNet_MS_language_messdef_mesok_re_admin_4&adminname
		IF Session("DatabaseErr") <> "ok_now" Then
			Call logok()
		End IF	
	Else
		IF Session("DatabaseErr") <> "ok_now" Then
			Call logerr() 
		End IF
		Response.Write "<meta http-equiv=Content-Type content=text/html;charset="& LingFengNet_MS_language_meta_mes_1 &"><script>" 
		Response.Write "alert('"& LingFengNet_MS_language_Warning_login_2 &"');" 
		Response.Write "history.go(-1);" 
		Response.Write "</script>" 
		Response.End			
	End IF
	Response.Redirect "m_admin_stlist"&Get_Suffix()
End IF
%>
<head>
<title><%= LingFengNet_MS_language_title_login %></title>
<%  
  Call htmlmeta() 
%> 

<link rel="stylesheet" href="../style/css/<%= LingFengNet_MS_web_css %>.css" type="text/css">
<link rel="stylesheet" href="../style/css/m_common.css" type="text/css">
<link rel="shortcut icon" href="../pic/favicon.ico" type="image/x-icon">
<link rel="bookmark" href="../pic/favicon.ico" type="image/x-icon">
<style type="text/css">	
.wdlf_liuYan_tiJiao{
	margin-bottom: 10px;
}	
</style>
</head>
<body onkeydown="EnableKey()" >
<%
Call htmltop()
%>
 <div class="wdlf_login bgc">
 	<form  name="myform" method="post" action="m_admin_login<%= Get_Suffix() %>" onSubmit="return checklogin()">
	 	<!--用户名-->
		<div class="wdlf_common_detail_item" >
			<div class="wdlf_common_detail_itemContent">
				<span style="color: #FF0000;position: relative;right: 5px;">*</span><%= LingFengNet_MS_language_messdef_login_name %>
			</div>
			<div class="wdlf_div_input">
				<input type="text" name="LingFengNet_MS_adminname" maxlength="25" size="25"   >
			</div>
		</div>
		
		<!--密码-->
	 	<div class="wdlf_common_detail_item" >
			<div class="wdlf_common_detail_itemContent">
				<span style="color: #FF0000;position: relative;right: 5px;">*</span><%= LingFengNet_MS_language_messdef_login_pass %>
			</div>
			<div class="wdlf_div_input">
				<input type="password" name="LingFengNet_MS_adminpass" maxlength="25" size="25"   >
			</div>
		</div>
	 	
	 	<!--认证码-->
		<div class="wdlf_common_detail_item" style="height: 100px;" id="wdlf_yanzhengma">
			<div class="wdlf_common_detail_itemContent">
				<span style="color: #FF0000;position: relative;right: 5px;">*</span><%= LingFengNet_MS_language_messdef_login_Att %>
			</div>
			<div class="wdlf_div_input">
				<input type="text" name="reg" size="8"  style="width: 47%;" maxlength="10" > 
		  		<img id="verifypic" src="showcode_math<%= Get_Suffix() %>" border="1" align="absmiddle" onClick="newverifypic()">
		  		<p style="margin: 0;"><%= LingFengNet_MS_language_messdef_login_right %></p>
				<input name=set type=hidden id="set" value="ok">	
			</div>
		</div>
		<!--提交-->
		<div class="wdlf_liuYan_tiJiao">
			<input type="submit" name="Submit" value="<%= LingFengNet_MS_language_messdef_login_submit %>" class="wdlf_liuYan_tiJiao_btn buttonface">
			<input type="reset" name="Submit" value="<%= LingFengNet_MS_language_messdef_login_reset %>" class="wdlf_liuYan_tiJiao_btn buttonface">
		</div>
	</form>
</div>
<%
Call htmlend() ' 底部区域
%>
<script src="../common/md532.js"></script>
<script  src="../common/jquery-3.2.1.min.js"></script>
<script>
function checklogin() {
	if (document.myform.LingFengNet_MS_adminname.value == "") {
		alert("<%= LingFengNet_MS_language_Warning_login_1 %>");
		myform.LingFengNet_MS_adminname.focus();
		return false;
	}
	if (document.myform.LingFengNet_MS_adminpass.value == "") {
		alert("<%= LingFengNet_MS_language_Warning_login_1 %>");
		myform.LingFengNet_MS_adminpass.focus();
		return false;
	}
	if (document.myform.reg.value == "") {
		alert("<%= LingFengNet_MS_language_Warning_login_1 %>");
		myform.reg.focus();
		return false;
	}
	document.getElementById("LingFengNet_MS_adminpass").value = md5(document.getElementById("LingFengNet_MS_adminpass").value);
	return true;
}

function newverifypic(){
	var timenow = new Date().getTime();
	url="showcode_math<%= Get_Suffix() %>";
	id = url.indexOf('?');
	if(id >= 0 ){
		if(id == (url.length-1))
			url = url + "t=" + timenow;
		else 
			url = url + "&t=" + timenow;
	}else{
		url = url + "?t=" + timenow;
	}

	document.getElementById("verifypic").src = url;
}
//控制logo大小
$('.wdlf_commonHead').css('height', $('.wdlf_commonHead .wdlf_commonHead_right img').css('height'))	
</script>
</body>
</html>