<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<%Const dbdns = "../"%>
<!--#include file="../AppCode/Conn.asp"-->
<!--#include file="../AppCode/fun/function.asp"-->
<!--#include file="../AppCode/Pager.asp"-->
<%
TableID = Cdbl(Request.QueryString("id"))
TypeID = 2
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>发表评论</title>
<link rel="stylesheet" type="text/css" href="../images/pl.css">
<script type="text/javascript" src="../js/pl.js"></script>
</head>

<body>
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="table-layout: fixed; word-wrap:break-word;">
  <tr>
    <td><form method="post" action="./pls.asp">
      <textarea name="Content" id="Content"></textarea>
      <br />
      我的名字：
      <input name="UserName" type="text" id="UserName" maxlength="25" />
      <input type="button" name="bntSubmit" id="bntSubmit" value="立即发表" onclick="chk(this.form);" />
      <input name="TableID" type="hidden" id="TableID" value="<%=TableID%>" />
      <input name="TypeID" type="hidden" id="TypeID" value="<%=TypeID%>" />
	  <input name="sID" type="hidden" id="sID" value="<%=Session.SessionID%>" />
    </form>
<%
PageSize = 10
PageNo = Trim(Request.QueryString("PageNo"))
If PageNo = "" Then PageNo = 1
LC = (PageNo-1) * PageSize
Sql = "select * from Ok3w_Guest where TypeID=2 and TableID=" & TableID
If Application(SiteID & "_Ok3w_SiteIsGuest")="1" Then Sql = Sql & " and IsPass=1"
Sql = Sql & " order by ID desc"
Set Page = New TurnPage
Call Page.GetRs(Conn,Rs,Sql,PageSize)
If Not(Rs.Eof And Rs.Bof) Then
Do While Not Rs.Eof And Not Page.Eof
	LC = LC + 1
	Response.Write("<div class=""list"">")
	Response.Write("<div class=""t""><strong>" & LC & "楼</strong>" & Rs("UserName") & " 于 " & Rs("AddTime") & " 说：</div>")
	Response.Write("<div class=""c"">" & OutStr(Rs("Content")) & "</div>")
	Response.Write("</div>")
	Rs.MoveNext
	Page.MoveNext
Loop
Rs.Close
Call Page.PageAspList("./plw.asp?id=" & TableID & "&")
End If
Set Rs = Nothing
Call CloseConn()%></td>
  </tr>
</table>
</body>
</html>