<!--#include file="conn.asp"-->
<!--#include file="function.asp"-->
<!--#include file="char.inc"-->
<%
dim shu,order,path,ss,oo,tt
shu = ChkRequest(request.querystring("shu"), 1)
order=request("order")
title=ChkRequest(request.querystring("title"), 0)
Path = "./"
if shu<>"" then   '显示数目，不加为6
	ss=shu
else
	ss=9
end if
if order="reviewid" then  '排序方式，click为按点击率
	oo="UpdateTime"
else
	oo="reviewid"
end if

if title<>"" then   '显示字数数目，不加为10
	nn=title
else
	nn=60
end if %>
<div>
<ul class="list">
<%
Set Rs=Conn.Execute("Select Top "&ss&" * From "& db_wygkcn_Review_Table &" Where Passed=1 Order By "&oo&" Desc")
If Rs.Eof And Rs.Bof Then
Response.Write("<li>·暂时没有留言</li>")
Else
Do While Not Rs.Eof
title=nohtml(CheckStr(Trim(Rs("Content"))))'获取表格中留言字段内容并替换格式符
%>
<li>
<%if rs("EC_ArticleID")>0 and rs("passed")=1 then%>		
  ·评论：&nbsp;<A href="wygkcn_ShowArticle.asp?EC_ArticleID=<%=rs("EC_ArticleID")%>" title="<%=CutStr(title,60)%>" target="_blank"><%=CutStr(title,nn)%></A><%if tt=1 then%><%end if%><%if date()-rs("updatetime")<2 then%>&nbsp;<img Src="images/new.gif">
<%end if%>			
<%else%>		
<%if rs("EC_ArticleID")<0 and rs("passed")=1 then%> 			
  ·留言：&nbsp;<A href="wygkcn_GuestBook.asp?ReViewID=<%=rs("ReViewID")%>" title"给管理员的悄悄话，非管理员不能查看!" target="_blank"><font color=green>悄悄话!</font></A>
   <%if date()-rs("updatetime")<2 then%>&nbsp;<img src="images/new.gif"><%end if%>
<%else%>			
  ·留言：&nbsp;<A href="wygkcn_GuestBook.asp?ReViewID=<%=rs("ReViewID")%>" title="<%=CutStr(title,60)%>" target="_blank"><%=CutStr(title,nn)%></A><%if date()-rs("updatetime")<2 then%>&nbsp;<img src="images/new.gif"><%end if%>
<%End If%>
</li>
<%
End If
Rs.Movenext 
Loop 
End If
Rs.Close
Set Rs=nothing
%>
</ul>
</div>