爱问知识人 爱问教育 医院库

求好心asp高手帮看下代码

首页

求好心asp高手帮看下代码

好心的高手帮看一下这段代码 写的是什么意思 每一段都表达的什么 好心的高手帮看些 解释下无限感激中
<%sub backupdata()
    Dbpath=request.form("Dbpath")
    Dbpath=server.mappath(Dbpath)
    bkfolder=request.form("bkfolder")
    bkdbname=request.form("bkdbname")
    Set Fso=server.createobject("scripting.filesystemobject")
    if fso.fileexists(dbpath) then
    If CheckDir(bkfolder) = True Then
    fso.copyfile dbpath,bkfolder& "\"& bkdbname
    else
    MakeNewsDir bkfolder
    fso.copyfile dbpath,bkfolder& "\"& bkdbname
    end if
    response.write "<SCRIPT LANGUAGE=JavaScript>alert (' 成功备份数据!');window.location.href='admin_backupdata.asp';</script>"
        response.end
     Else
    response.write "<SCRIPT LANGUAGE=JavaScript>alert (' 备份数据库失败,您要备份的数据库不存在!');window.location.href='admin_backupdata.asp';</script>"
        response.end
    End if
end sub
'------------------检查某一目录是否存在-------------------
Function CheckDir(FolderPath)
  folderpath=Server.MapPath(".")&"\"&folderpath
    Set fso1 = CreateObject("Scripting.FileSystemObject")
    If fso1.FolderExists(FolderPath) then
       '存在
       CheckDir = True
    Else
       '不存在
       CheckDir = False
    End if
    Set fso1 = nothing
End Function
'-------------根据指定名称生成目录---------
Function MakeNewsDir(foldername)
    Set fso1 = CreateObject("Scripting.FileSystemObject")
        Set f = fso1.CreateFolder(foldername)
        MakeNewsDir = True
    Set fso1 = nothing
End Function  %>

提交回答
好评回答

其他答案

类似问题

换一换
  • C#/.NET 相关知识

  • 电脑网络技术
  • 电脑网络

相关推荐

正在加载...
最新问答 推荐信息 热门专题 热点推荐
  • 1-20
  • 21-40
  • 41-60
  • 61-80
  • 81-100
  • 101-120
  • 121-140
  • 141-160
  • 161-180
  • 181-200
  • 1-20
  • 21-40
  • 41-60
  • 61-80
  • 81-100
  • 101-120
  • 121-140
  • 141-160
  • 161-180
  • 181-200
  • 1-20
  • 21-40
  • 41-60
  • 61-80
  • 81-100
  • 101-120
  • 121-140
  • 141-160
  • 161-180
  • 181-200
  • 1-20
  • 21-40
  • 41-60
  • 61-80
  • 81-100
  • 101-120
  • 121-140
  • 141-160
  • 161-180
  • 181-200

热点检索

  • 1-20
  • 21-40
  • 41-60
  • 61-80
  • 81-100
  • 101-120
  • 121-140
  • 141-160
  • 161-180
  • 181-200
返回
顶部
帮助 意见
反馈

确定举报此问题

举报原因(必选):