最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
asp利用fso生成html页面
时间:2022-06-30 11:44:08 编辑:袖梨 来源:一聚教程网
asp利用fso生成html页面,此文章是我大二时写的了,就是利用asp自带组件fso来进行用户文件上传时就生成html文件用了,它也很好的判断文件名称是否存在了,等提示
dim path,filename,filetype,fileconten,fso
path=request("path")
filename=html_encode(request("filename"))
filecontent=request("filecontent")
filetype=request("filetype")
if instr(filename,"*")>0 or instr(filename,"?")>0 or instr(filename,"&")>0 or len(filename)
response.Write("")
response.end
else
set fso=server.createobject("scripting.filesystemobject")
if fso.fileexists(path&filename&filetype) then
response.Write("")
response.End()
end if
set input=fso.createtextfile(server.mappath(path&filename&filetype),true)
input.writeline(filecontent)
input.close
if err then
response.Write("")
else
%>
end if
end if
%>
原创: www.111com.net 转请注明
相关文章
- 《Disney Lorcana: Wilds Unknown》预购开启 首批《Toy Story》及皮克斯卡牌购买指南 07-29
- 车来了赶车闹钟如何设置 07-29
- 崩坏星穹铁道余晖残卷巨剑守护打法攻略 07-29
- 崩坏星穹铁道砂金角色部分背景介绍 07-29
- 崩坏3雷电芽衣什么时候上线 07-29
- 玩具熊的五夜后宫4代噩梦气球男孩Nightmare Balloon Boy介绍 07-29