asp的两种生成静态比较
一个是fso,另一个是objStream
在utf-8下 用fso生成静态的,要用强行转换,就是
但生成的代码会比原来.asp的大一倍,代码如下fso代码如下
不过下面的代码有些服务器不支持,原先我是用下面的生成方式,但那时服务器不支持
在utf-8下 用fso生成静态的,要用强行转换,就是
Set Fout = Fso.CreateTextFile(Server.Mappath(""&Filename&""),true,true)
但生成的代码会比原来.asp的大一倍,代码如下fso代码如下
Set Fso = Server.CreateObject("Scripting.FileSystemObject")
Set Fout = Fso.CreateTextFile(Server.Mappath(""&Filename&""),true,true)
Fout.Write(Body)
Fout.Close
Set Fout=nothing
Set Fso=nothing
Set Fout = Fso.CreateTextFile(Server.Mappath(""&Filename&""),true,true)
Fout.Write(Body)
Fout.Close
Set Fout=nothing
Set Fso=nothing
不过下面的代码有些服务器不支持,原先我是用下面的生成方式,但那时服务器不支持
Set objStream = Server.CreateObject("ADODB.Stream")
With objStream
.Open
.Charset = "utf-8"
.Position = objStream.Size
.WriteText=Body '//模版+数据
.SaveToFile server.mappath(Filename),2
.Close
End With
Set objStream = Nothing
With objStream
.Open
.Charset = "utf-8"
.Position = objStream.Size
.WriteText=Body '//模版+数据
.SaveToFile server.mappath(Filename),2
.Close
End With
Set objStream = Nothing
域名空间出售
核电站是不是有害的呢?

很多人都没留意这一点的。
留意留意
很多人都没留言这一点的。
很多人都没留言这一点的。