<!-- #include file="../Inc.asp" -->
<!-- #include file="../ydzq.asp" -->
<!-- #include file="conn.asp" -->
<%Call Head()
call zonecard("好友动态","left")
if myid=clng(uid) then
response.write "<a href=""index_gl.asp?uid="&uid&"&amp;sid="&sid&"&amp;saytk="&saytk&""">个人中心</a>|"
end if
response.write "<a href=""index.asp?uid="&uid&"&amp;sid="&sid&"&amp;saytk="&saytk&""">主页</a>|"&_
               "<a href='blog.asp?uid="&uid&"&amp;sid="&sid&"&amp;saytk="&saytk&"'>日志</a>|"&_
               "<a href='user_info.asp?uid="&uid&"&amp;sid="&sid&"&amp;saytk="&saytk&"'>个人档</a><br/>"
dim tpye
tpye= Request.QueryString("tpye")
if tpye="" then tpye=3
Response.write "【好友动态】<br/>"&_
               "<a href=""frzonedt_list.asp?sid="&sid&"&amp;saytk="&saytk&""">全部</a>"&_
               ".<a href=""frzonedt_list.asp?tpye=1&amp;sid="&sid&"&amp;saytk="&saytk&""">日志</a>"&_
               ".<a href=""frzonedt_list.asp?tpye=2&amp;sid="&sid&"&amp;saytk="&saytk&""">说说</a><br/>"


dim rs2,fdid
set rs2=Server.CreateObject("ADODB.Recordset")
rs2.open"select * from myfriend where cid="&myid&" order by id desc",conn,1,1
if rs2.eof Then
   Response.write "暂无好友更新动态<br/>"
   else
Dim PageSize,i
	PageSize=10					
	Dim Count,page,pagecount,gopage			
	gopage="frzonedt_list.asp?sid="&sid&"&amp;tpye="&tpye&"&amp;"
	Count=rs2.recordcount	
  page=clng(request("page"))
	if page<=0 or page="" then page=1		
	pagecount=(count+pagesize-1)\pagesize	
        if page>pagecount then page=pagecount
	rs2.move(pagesize*(page-1))
	For i=1 To PageSize     						
	If rs2.eof Then Exit For	
response.write ""&i+(page-1)*PageSize&"."
a=1

set rs3=Server.CreateObject("ADODB.Recordset")
rs3.open"select id,rc,xcid,htm,fgid,rjid,txt from frzonedt where fgid="&rs2("did")&" order by htm desc",conn,1,1
if rs3.eof then

Else
dim k
k=rs3.recordcount
i=1
do while ((not rs3.EOF) and i <=cint(review))
response.write""&k&"."
response.write ubb2(rs3("txt"))&""
if rs3("rc")=1 then
dim rsrj,rjid,rjtxt,rjtit,rjtm,rjhc
set rsrj=Server.CreateObject("ADODB.Recordset")
rsrj.open"select id,txt,tit,tm,hc from [zonerj] where rc=0 and [ID]="&rs3("rjid"),conn,1,1
rjid=rsrj("id")
rjtit=rsrj("tit")
rjtm=rsrj("tm")
rjhc=rsrj("hc")
rjtxt=left(rsrj("txt"),50)
if len(rsrj("txt"))>50 then
rjtxt=rjtxt+"..."
End if
rsrj.close
set rsrj=nothing
response.write "《"&UBB(rjtit)&"》<br/>"&_
               ""&UBB2(rjtxt)&"<br/>"&_
               "[" & fordate(rjtm) & "]"&_
               "<br/>评论("&UBB(rjhc)&")<br/>"
else
Dim rsxc,xcid,xctit,xctm,xcrc
set rsxc=Server.CreateObject("ADODB.Recordset")
rsxc.open"select * from zoness where id="&rs3("xcid"),conn,1,1
xcid=rsxc("id")
xctit=rsxc("tit")
xctm=rsxc("tm")
xcrc=rsxc("rc")
rsxc.close
set rsxc=nothing
response.write ":"&UBB(xctit)&"<br/>"&_
               "[" & fordate(xctm) & "]"&_
               "<br/>评论("&UBB(xcrc)&")<br/>"
end if
rs3.Movenext
k=k-1
i=i+1
Loop
end if


rs3.close
set rs3=nothing
rs2.moveNext
 	Next

 if page-pagecount<0 then response.write "<a href="""&gopage&"page="&page+1&""">下一页</a>"&chr(13)
	if page>1 then response.write "<a href="""&gopage&"page="&page-1&""">上一页</a>"&chr(13)

response.write "<br/>("&page&"/"&pagecount&")共"&count&"条动态"
	if pagecount>1 then response.write "<input name=""page"" format=""*N"" value="""&page&""" type=""text"" maxlength=""5"" emptyok=""true"" size=""2""/><a href="""&gopage&"page=$(page)"">页</a>"
End If

rs2.close
set rs2=Nothing




call zonelast()
Call Headsay()
%>                          