<%@language=vbscript codepage=936 %>
<%
option explicit
response.buffer= True
Response.Expires = -1
Response.ExpiresAbsolute = Now() - 1
Response.Expires = 0
Response.CacheControl = "no-cache"
Const ChannelID=6
%>
<!--#include file="../Conn.asp"-->
<!--#include file="../Inc/Cl_Const.asp"-->
<!--#include file="../Inc/Cl_ClsUbb.asp"-->
<!--#include file="../Inc/Cl_Function_Public.asp"-->
<!--#include file="../Inc/Cl_Function_Guest.asp"-->
<%
dim rsGuest,sqlGuest
dim UserGuestName,UserSex,UserEmail,UserIM,UserHomepage,UserQQ,UserIcq,UserMsn
dim WriteName,WriteType,WriteSex,WriteEmail,WriteQQ,WriteIcq,WriteMsn,WriteHomepage
dim WriteFace,WriteImages,WriteTitle,WriteContent,SaveEdit,SaveEditId
dim GuestType,AdminReplyContent,PageTitle
dim Action,SubmitType,GuestPath,TitleName,ComeUrl
Cl.LoadTemplates("guest")
Set rsGuest	= Server.CreateObject("ADODB.Recordset")
Cl.Path		= Cl.lanstr(1)&"<a href='" & Cl.WebDir & Cl.ChannelDir & "'>" & Cl.ChannelName & "</a>"
Cl.Title	= Cl.Web_info(1) & " >> " & Cl.ChannelName
MaxPerPage	= 5
SaveEdit	= 0
strFileName	= "Index.asp"
TitleName	= Cl.ChannelName
GuestPath	= Cl.WebDir&"images/guestbook/"
Action		= request("Action")
keyword		= Trim(request("keyword"))
CurrentPage	= Cl.ChkClng(request("page"))
ComeUrl		= Trim(request("ComeUrl"))
if ComeUrl="" then ComeUrl=Request.ServerVariables("HTTP_REFERER")
if ComeUrl="" then ComeUrl="Index.asp"
if Cl.UserID>=1 or Not Cl.ChkUserLevel(Cl.Web_Setting(35),"5") then
	GuestType=1
else
	GuestType=0
end if
if keyword<>"" then 
	keyword=Cl.ReplaceBadChar(keyword)
	keyword=Replace(keyword,"[","")
	keyword=Replace(keyword,"]","")
end if
if keyword<>"" then TitleName="搜索含有 <font color=red>"&keyword&"</font> 的留言"
Select Case Action
Case "write"
	PageTitle="签写留言"
Case "savewrite"
	PageTitle="保存留言"
Case "reply"
	PageTitle="回复留言"
Case "replyadmin"
	PageTitle="管理员回复留言"
Case "edit"
	PageTitle="编辑留言"
Case "del"
	PageTitle="删除留言"
Case Else
	PageTitle="首页"
End Select
Cl.Path		= Cl.lanstr(1) & "<a href='" & Cl.Web_info(4) & "'>" & Cl.Web_info(0) & "</a>&nbsp;&gt;&gt;&nbsp;<a href='" & Cl.WebDir & Cl.ChannelDir & "'>" & Cl.ChannelName & "</a>&nbsp;&gt;&gt;&nbsp;" & PageTitle
Cl.Title	= Cl.Web_info(1) & " >> " & Cl.ChannelName & " >> " & PageTitle
%>
