mdb_copy.asp
来自「数据结构课程设计之最小生成数的K算法的实现 简短 简洁」· ASP 代码 · 共 64 行
ASP
64 行
<%Admin="SysMdbRC"%>
<html>
<head>
<meta HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=gb2312">
<title>※教师科研信息管理系统(ACCESS+ASP) </title>
<link rel="stylesheet" href="main.css" type="text/css">
</head>
<body topmargin="1">
<div align="center">
<center>
<%
if request("type")="save" then
KYDBMDBname=request("KYDB")
KYDBMDBnameNew=request("KYDBNew")
if KYDBMDBname="" or KYDBMDBnameNew="" then
KYDBMsg="错误:文件名不能为空."
end if
if KYDBMDBname=KYDBMDBnameNew then
KYDBMsg="错误:文件名相同."
end if
if KYDBMsg="" then
Set fs=Server.CreateObject("Scripting.FileSystemObject")
fs.CopyFile Server.MapPath("data\"&KYDBMDBname&""),Server.MapPath("data_backup\"&KYDBMDBnameNew&"")
KYDBMsg="成功:已经成功备份数据库("&KYDBMDBnameNew&")!"
Set fs=nothing
end if
%>
<table border="0" cellspacing="0" style="border-collapse: collapse" cellpadding="0">
<tr>
<td width="100%"><font color="#FF0000">·</font><%=KYDBMsg%> 时间:<%=Now()%></td>
</tr>
</table>
<%end if%>
<table border="0" cellspacing="1" class="tableBorder" align="center" width="280" >
<tr>
<th width="100%" align="left" ><font color="#FFFFFF"><b>备份数据库</b></font></th>
</tr>
<tr>
<td width="100%" class="forumRowHighlight">
<font color="#000080"><b>系统数据库备份</b></font></td>
</tr>
<form action="mdb_copy.asp?type=save" method="post">
<tr>
<td width="100%" class="forumRow">
原数据文件名
<input name="KYDB" value="KYDB.mdb" size="20" style="border-style: solid; border-width: 1"></td>
</tr>
<tr>
<td width="100%" class="forumRow">
备份数据库名
<input name="KYDBNew" value="KYDB_backup.mdb"" size="20" style="border-style: solid; border-width: 1"></td>
</tr>
<tr>
<td width="100%" class="forumRowHighlight" >
<p align="center">
<input name="b1" type="submit" value="确认备份"></p>
</td>
</form>
</tr>
</table>
</center>
</div>
</body>
</html>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?