ASP读写文件
作者:刚子 日期:2008-08-07
ASP读取文件
程序代码
ASP写入文件
程序代码
程序代码set fso=server.createobject("scripting.filesystemobject")
set file=fso.opentextfile(server.mappath("index.html"),1,true) '1读取 2写入 8追加
filestr=file.readall
response.write filestr
file.close
set file = nothing
set fso = nothing
set file=fso.opentextfile(server.mappath("index.html"),1,true) '1读取 2写入 8追加
filestr=file.readall
response.write filestr
file.close
set file = nothing
set fso = nothing
ASP写入文件
程序代码set fso = createobject("scripting.filesystemobject")
set file = fso.opentextfile(server.mappath("index.html"),2,true) '1读取 2写入 8追加
file.write "hello world!"
file.close
set file = nothing
set fso = nothing
set file = fso.opentextfile(server.mappath("index.html"),2,true) '1读取 2写入 8追加
file.write "hello world!"
file.close
set file = nothing
set fso = nothing
评论: 0 | 引用: 0 | 查看次数: -
发表评论
上一篇
下一篇

文章来自:
Tags: