<!DOCTYPE html>
<%@ language="vbscript" codepage="936" %>
<%
'========================================================================================
' 文 件 名: redata.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
'========================================================================================
%>
<!-- #include file="../common/sub_inc.asp" -->
<!-- #include file="../common/commfun.asp" -->
<!-- #include file="../common/ip_purview.asp" -->
<!-- #include file="../common/connect.asp" -->
<%flg = "man"%>
<!-- #include file="../common/purview.asp" -->
<head>
<title><%= LingFengNet_MS_language_title_redata %></title>
<%  
  Call htmlmeta() 
%> 
<link rel="stylesheet" href="../style/css/<%= LingFengNet_MS_web_css %>.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">
</head>
<body onkeydown="EnableKey()" >
<%
Call htmltop()
Call htmlbr()
Call htmladminmen()
Call htmlbr()
%>
<table width="<%= LingFengNet_MS_web_w %>" border="0" cellspacing="0" cellpadding="0" align="center">
  <tr> 
    <td class="bgc2"> 
      <table width="100%" border="0" cellspacing="1" cellpadding="3">
        <tr class="bgc"> 
          <td height=20 width=25% class="bgc"> 
            <table width=95% cellspacing=0 cellpadding=0 align="center" >
              <tr> 
                <td height=25 > &ensp;&ensp;<b><br>
                  <%= LingFengNet_MS_language_redata_mes_1 %> <br>
                  </b></td>
              </tr>
<%
IF IsObjInstalled("Scripting.FileSystemObject") Then
	Set fso = Server.Createobject("Scripting.FileSystemObject")
	Dim method
	method = Request.Querystring("method")
	IF method = "" Then 
		FoldName=Server.Mappath("../data") 
		Set f1 = fso.GetFolder(FoldName)
		Set pFiles = f1.Files
%>
              <form method="post" action="admin_redata<%= Get_Suffix() %>?method=Backup">
                <tr> 
                  <td height=100 > &ensp;&ensp; 
                    <p> <%= LingFengNet_MS_language_redata_mes_2 %>:  
                      <select name="DBpath">
<%
		For each file in f1.Files
			IF Right(file.name, 4) = ".asp" and Right(file.name, 4) = ".mdb" and Left(file.name, 1) = "#" Then tempwrite = tempwrite & "<option value=" & file.name &">" & file.name &"</option>"
		Next 
		Response.Write tempwrite
		Set f1 = Nothing
		Set fso = Nothing
%>
                      </select>
                      &ensp; 
                      <input type=submit value="<%= LingFengNet_MS_language_redata_mes_sub %>" name="submit" class="buttonface">
                      <br>
                      <br>
                      <br>
                      &ensp;&ensp;<%= LingFengNet_MS_language_redata_mes_3 %> <br>
                      <br>
                      &ensp;&ensp;<%= LingFengNet_MS_language_redata_mes_4 %><br>
                    </p>
                </tr>
              </form>
              <%

		Set f1 = Nothing
		Set pFiles = Nothing
	ElseIF method = "Backup" Then 
		Dbpathys = Trim(Request.Form("Dbpath"))
		Dbpath = "../data/" & Dbpathys 
		Dbpath = Server.Mappath(Dbpath) 
		db2 = Server.Mappath(dbnow)
		IF fso.FileExists(dbpath) Then 
			fso.copyfile dbpath, db2, True
			logstr = LingFengNet_MS_language_Warning_redata_4 & Dbpathys
			Call logtodo(logstr, 1, "ok")
			Response.Write "<tr><td height=25><br><br><li>"& LingFengNet_MS_language_Warning_redata_1 &"</td></tr>"
		Else
			logstr = LingFengNet_MS_language_Warning_redata_5 & Dbpathys
			Call logtodo(logstr, 1, "err")
			Response.Write "<tr><td height=25><br><br><li>"& LingFengNet_MS_language_Warning_redata_2 &"</td></tr>" 
		End IF
		Response.Write "<tr><td height=25><br><li>"& LingFengNet_MS_language_Warning_redata_3 &"！<br><br></td></tr>"
	End IF
	Set fso = Nothing
Else
%>
              <tr> 
                <td height=30 > 
                  <li><%= LingFengNet_MS_language_redata_mes_5 %><b>FSO</b><%= LingFengNet_MS_language_redata_mes_6 %>。
                </td>
              </tr>
<%End IF%>
            </table>
          </td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<table width="<%= LingFengNet_MS_web_w %>" border="0" cellspacing="0" cellpadding="0" align="center">
  <tr> 
    <td> </td>
  </tr>
</table>
</body>
</html>
<%
Call htmlbr()
Call htmlend()
%>