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