restoredbdo.asp
来自「个人备忘系统一个不错的备忘软件.专供刚学ASP的人学习. 代码简单易懂 m」· ASP 代码 · 共 24 行
ASP
24 行
<%
if session("user")="" or session("group")<>1 then
response.write("<script>alert('您没有权限,请与管理员联系');window.location.href('vir.asp')</script>")
response.end
end if
%>
<%
Dbpath=request.form("Dbpath")
backpath=request.form("backpath")
if dbpath="" then
response.write("<script>alert('请输入您要恢复成的数据库全名');window.location.href('restoredb.asp')</script>")
else
Dbpath=server.mappath(Dbpath)
end if
backpath=server.mappath(backpath)
'Response.write Backpath
Set Fso=server.createobject("scripting.filesystemobject")
if fso.fileexists(dbpath) then
fso.copyfile Dbpath,Backpath
response.write("<script>alert('数据恢复成功!');window.location.href('restoredb.asp')</script>")
else
response.write("<script>alert('没找到备份数据!');window.location.href('restoredb.asp')</script>")
end if
%>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?