
<!-- #include file="../conn.asp" -->
<!-- #include file="admin.asp" -->
<%call ling()
Call Head()
Call saycardd("评论管理")

dim rs
Set rs = Server.CreateObject("ADODB.Recordset")
sql="Select * from pin Where type=1 order by id desc"
rs.open sql,conn,1,1
If Not rs.eof	Then
	Dim PageSize,i
	PageSize=10							
	Dim Count,page,pagecount,gopage			
	gopage="adminpin.asp?sid="&sid&"&amp;saytk="&saytk&"&amp;"
	Count=conn.execute("Select count(ID) from [pin] where type=1")(0)	
	page=int(request.QueryString ("page"))
	if page<=0 or page="" then page=1		
	pagecount=(count+pagesize-1)\pagesize	
        if page>pagecount then page=pagecount	
	rs.move(pagesize*(page-1))					
	For i=1 To PageSize
        						
	If rs.eof Then Exit For				
%>[<a href="delpin.asp?sid=<%=sid%>&amp;id=<%=rs("id")%>&amp;saytk=<%=saytk%>">删除</a>]<%=i+(page-1)*PageSize%>.<%=rs("ip")%>说:<br/><%=UBB1(rs("pin"))%><%=fordate(rs("pltime"))%><br/>
<%     
	rs.moveNext
  								
	Next
	if page-pagecount<0 then response.write "<a href="""&gopage&"page="&page+1&""">下页</a>"
	if page>1 then response.write "<a href="""&gopage&"page="&page-1&""">上页</a>"
	if pagecount>1 then response.write "<br/><b>"&page&"</b>/"&pagecount&"页"
if saytk=1 then
response.write "<input name=""page"" format=""*N"" value="""&page&""" type=""text"" maxlength=""5"" emptyok=""true"" size=""3""/><a href="""&gopage&"page=$(page)"">>></a>"
end if
Else
%>
	暂时没有评论！
<% end if%>
       <%
	rs.close
	conn.close
	set rs=nothing
	set conn=nothing

%>
<br/>
<a href="qkpin.asp?sid=<%=sid%>&amp;saytk=<%=saytk%>">[清空评论]</a><br/>
<a href="index.asp?sid=<%=sid%>&amp;saytk=<%=saytk%>">[图片管理]</a><br/>
<a href="../index.asp?sid=<%=sid%>&amp;saytk=<%=saytk%>">[后台管理]</a>
<%response.write""
call head3()%>