asp 中处理文件上传以及删除时常用的自定义函数
<%
””””””””””””””””””””””””””””””””””””
‘所有自定义的VBS函数
””””””””””””””””””””””””””””””””””””
function DeleteFile(Filename) ‘删除文件
if Filename then
Set fso = server.CreateObject(scr ipting.FileSystemObject)
if fso.FileExists
代码如下:<% ‘建立文件夹函数 Function CreateFolder(strFolder)’参数为相对路径 ‘首选判断要建立的文件夹是否已经存在 Dim strTestFolder,objFSO strTestFolder = Server.Mappath(strFolder) Set objFSO = CreateObject(“scr ipting.FileSystemObject”) ‘检查文件夹是否存在 If not objF