WEB开发网
开发学院WEB开发ASP 在线用表单建立文件夹 阅读

在线用表单建立文件夹

 2001-01-09 10:56:28 来源:WEB开发网   
核心提示:HTML格式的Form表单文件FOLDER.htm的内容:<form name="form1" method="post" action="folder-action.asp">Create a folder <input type=&quo
HTML格式的Form表单文件FOLDER.htm的内容:

<form name="form1" method="post" action="folder-action.asp">
Create a folder
<input type="text" name="name">
<input type="submit" name="Submit" value="Submit">
</form>

ASP文件FOLDER-ACTION.ASP

<%@ LANGUAGE = "VBScript" %>
<% Dim Name
Name = Request("Name")
set fs=createobject("scripting.filesystemobject")
MyFolder=server.mappath(""&name&"")
If NOT fs.folderexists(MyFolder) then
fs.createfolder(MyFolder)
End If
If fs.folderexists(MyFolder) then
%> Folder created successfully! Called
<%=MyFolder%>


<%Else%%>
There has been an error.
<%End If
%>

也可以下载zip文件,在http://designbliss.com.au/asp/download.asp?file=folder.zip

Tags:在线 表单 建立

编辑录入:爽爽 [复制链接] [打 印]
赞助商链接