生成静态首页
作者:cmscn 日期:2009-02-24
<%
dim objXmlHttp,binFileData,objAdoStream
set objXmlHttp = Server.CreateObject("Microsoft.XMLHTTP")
objXmlHttp.open "GET","http://"&request.ServerVariables("HTTP_HOST")&"/index1.asp",false
objXmlHttp.send()
binFileData = objXmlHttp.responseBody
set objAdoStream = Server.CreateObject("ADODB.Stream")
objAdoStream.Type = 1
objAdoStream.Open()
objAdoStream.Write(binFileData)
objAdoStream.SaveToFile server.MapPath("../index.html"),2
objAdoStream.Close()
set objAdoStream=nothing
set objXmlHttp=nothing
response.write"<script language=javascript>alert('首页生成完成!');this.location.href='manage_main.asp';</script>"
%>
评论: 0 | 引用: 0 | 查看次数: 420
发表评论