<!--#include file="seeion.asp"-->
<!--#include file="../module/about_add.asp"-->
<%
'######################################
' 启点在线企业网站管理系统中英文版
' Enterprise Web Site Management System
' 官方网站：http://www.kelvinvt.com
' 联系QQ：15038883
' 淘宝店： http://kelvinvt.taobao.com
'######################################
%>
<%
Template="../template/about.htm" '模版
str=ReadFromUTF(Template,"utf-8") '编码
content=Replace(str,"{Kdesign_webtitle}",Kdesign_webtitle) '替换
content=Replace(content,"{Kdesign_title}",Kdesign_title)
content=Replace(content,"{Kdesign_keyword}",Kdesign_keyword)
content=Replace(content,"{Kdesign_description}",Kdesign_description)
content=Replace(content,"{Kdesign_logo}",Kdesign_logo)
content=Replace(content,"{Kdesign_enurl}",Kdesign_enurl)
content=Replace(content,"{Kdesign_cnurl}",Kdesign_cnurl)
content=Replace(content,"{id}",id)
content=Replace(content,"{Kdesign_body}",Kdesign_body)
content=Replace(content,"{Kdesign_copyright}",Kdesign_copyright)
content=Replace(content,"{Kdesign_share}",Kdesign_share)
content=Replace(content,"{Kdesign_beian}",Kdesign_beian)
content=Replace(content,"{Kdesign_dz}",Kdesign_dz)
content=Replace(content,"{Kdesign_tel}",Kdesign_tel)
content=Replace(content,"{Kdesign_fax}",Kdesign_fax)
content=Replace(content,"{Kdesign_email}",Kdesign_email)
content=Replace(content,"{Kdesign_nav}",Kdesign_nav)
content=Replace(content,"{Kdesign_leftnav}",Kdesign_leftnav)
content=Replace(content,"{Kdesign_hot}",Kdesign_hot)
content=Replace(content,"{Kdesign_flink}",Kdesign_flink)
content=Replace(content,"{eqq}",eqq)
content=Replace(content,"{root}",root)


Filen="../about/"&id&".html" '静态存放位置
Call WriteToUTF(content,Filen) '生成静态页
If Not Err Then Response.Write "<a href='"&root&"/about/"&id&".html' target='_blank'>about/"&id&".html</a>...生成成功！</br>"

Function ReadFromUTF(TempString,CharSet) '路径；编码
Dim str
Set stm=server.CreateObject("adodb.stream")
stm.Type=2
stm.Mode=3
stm.Charset=CharSet
stm.Open
stm.loadfromfile Server.MapPath(TempString)
str=stm.readtext
stm.Close
Set stm=Nothing
ReadFromUTF=str
End Function

Function WriteToUTF(content,Filen) '将替换后的内容写入HTML文档,content为替换后的字符串,Filen为生成的文件名
Set objStream=Server.CreateObject("ADODB.Stream")
    With objStream
    .Open
    .Charset="utf-8" '编码，这里你可以改成任何编码
    .Position=objStream.Size
    .WriteText=content '模版+数据 写入内容
    .SaveToFile server.mappath(Filen),2 '生成文件路径
    .Close
    End With
Set objStream=Nothing
End Function
%>

