<%
Class DefaultCls
	Private AppI,J,I,A_title,B_title,A_BlogName,B_BlogName
	
	
	Public Sub Recommends_Photo(Quantity)

		IF IsHd=True Then
		IF Not CblogObj.IsCaheEmpty("Recommends_Photo") Then
			Set Rs=Conn.Execute("Select Top " & Quantity & " Article_ID,User_ID,Article_Title,Photo From Article Where Article_Hid<>1 And [Top]=1 AND Photo<>''And IsPhoto=1 Order By Article_ID Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "Recommends_Photo",Rs.GetRows()
				CblogObj.AddCaheDate "Recommends_Photo",Now()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		
		IF CblogObj.IsCaheArr("Recommends_Photo") Then
			Response.Write "<script type=""text/javascript"">"
			Response.Write "<!--" & Chr(13)
			Response.Write "var focus_width=374" & Chr(13)
			Response.Write "var focus_height=190" & Chr(13)
			Response.Write "var text_height=30" & Chr(13)
			Response.Write "var swf_height = focus_height+text_height" & Chr(13)
			Dim Pic,Url,Txt
			Pic="var pics='"
			For J=0 TO Ubound(CblogObj.Cahe("Recommends_Photo"),2)
				Pic=Pic & CblogObj.Cahe("Recommends_Photo")(3,J) & "|"
			Next
			Pic=MID(Pic,1,LEN(PIC)-1) & "'"
			Response.Write Pic & Chr(13)
			Url="var links='"
			For J=0 to Ubound(CblogObj.Cahe("Recommends_Photo"),2)
				Url=Url & CblogObj.GetDir(CblogObj.Cahe("Recommends_Photo")(1,J)) &"/show.asp?/_articleid/"& CblogObj.Cahe("Recommends_Photo")(0,J) &".html" & "|"
			Next
			Url=MID(Url,1,LEN(Url)-1) & "'"
			Response.Write Url & Chr(13)
			Txt="var texts='"
			For J=0 to Ubound(CblogObj.Cahe("Recommends_Photo"),2)
				Txt=Txt & Replace(Replace(CblogObj.Cahe("Recommends_Photo")(2,J),"'","’"),"|","") & "|"
			Next
			Txt=Replace(Txt,Chr(13),"")
			Txt=Replace(Txt,Chr(10),"")
			Txt=Replace(Txt,"<","&lt;")
			Txt=Replace(Txt,">","&gt;")
			Txt=Replace(Txt,Chr(34),"&quot;")
			Txt=MID(Txt,1,LEN(Txt)-1) & "'"
			Response.Write Txt & Chr(13)
			%>
			document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" width="'+ focus_width +'" height="'+ swf_height +'">');
			document.write('<param name="allowScriptAccess" value="sameDomain"><param name="movie" value="http://sports.qq.com/flash/playswf.swf"><param name=wmode value=transparent><param name="quality" value="high">');
			document.write('<param name="menu" value="false"><param name=wmode value="opaque">');
			document.write('<param name="FlashVars" value="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'">');
			document.write('<embed src="playswf.swf" wmode="opaque" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'" menu="false" bgcolor="#DADADA" quality="high" width="'+ focus_width +'" height="'+ swf_height +'" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');
			document.write('</object>');
		<%
			Response.Write "//-->"&Chr(13)
			Response.Write "</script>"&Chr(13)
		Else
			Response.Write "<div class=""focuspic"">" & Chr(13)
			Response.Write "<div class=""pic"">没有推荐图片2</div>" & Chr(13)
			Response.Write "<div class=""txt""></div>" & Chr(13)
			Response.Write "</div>" & Chr(13)
		End IF
		Else
		'Application.Contents.RemoveAll()
		IF Not CblogObj.IsCaheEmpty("Recommends_Photo") Then
			Set Rs=Conn.Execute("Select Top " & Quantity & " Article_ID,User_ID,Article_Title,Photo From Article Where Article_Hid<>1 And [Top]=1 AND Photo<>''And IsPhoto=1 Order By Article_ID Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "Recommends_Photo",Rs.GetRows()
				CblogObj.AddCaheDate "Recommends_Photo",Now()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		
		IF CblogObj.IsCaheArr("Recommends_Photo") Then
			Response.Write "<script type=""text/javascript"">"
			Response.Write "function selectLayer1(i){"
			Response.Write "switch(i){"
			For J=1 TO Ubound(CblogObj.Cahe("Recommends_Photo"),2)+1
				Response.Write "case "& J &":"
				For i=1 TO Ubound(CblogObj.Cahe("Recommends_Photo"),2)+1
					IF J=I Then
						Response.Write "document.getElementById(""Recommends_Photo"&i&""").style.display=""block"";" & Chr(13)
					Else
						Response.Write "document.getElementById(""Recommends_Photo"&i&""").style.display=""none"";" & Chr(13)
					End IF
				Next
				Response.Write "break;" & Chr(13)
			Next
			Response.Write " }}</script>" & Chr(13)
			For J=0 to Ubound(CblogObj.Cahe("Recommends_Photo"),2)
				IF J=0 Then
					Response.Write "<div id=""Recommends_Photo" & J+1 & """ style=""display: block;"" class=""focuspic"">" & Chr(13)
				Else
					Response.Write "<div id=""Recommends_Photo" & J+1 & """ style=""display: none;"" class=""focuspic"">" & Chr(13)
			    End IF
				Response.Write "<div class=""pic""><a href="""& CblogObj.GetDir(CblogObj.Cahe("Recommends_Photo")(1,J)) &"/show.asp?/_articleid/"& CblogObj.Cahe("Recommends_Photo")(0,J) &".html""><img src="""& CblogObj.Cahe("Recommends_Photo")(3,J) &""" alt="""& CblogObj.Cahe("Recommends_Photo")(2,J) &""" border=""0"" /></a></div>" & Chr(13)
				Response.Write "<div class=""txt""><a href="""& CblogObj.GetDir(CblogObj.Cahe("Recommends_Photo")(1,J)) &"/show.asp?/_articleid/"& CblogObj.Cahe("Recommends_Photo")(0,J) &".html"">"& CblogObj.Cahe("Recommends_Photo")(2,J) &"</a></div>" & Chr(13)
				Response.Write "</div>" & Chr(13)
			Next
			Response.Write "<div class=""more"">"
			For J=1 To Ubound(CblogObj.Cahe("Recommends_Photo"),2)+1
				Response.Write "<h2><a href=""javascript:selectLayer1("&J&");"" target=""_self"">" & J & "</a></h2>" & Chr(13)
			Next
			Response.Write "</div>" & Chr(13)
		Else
			Response.Write "<div class=""focuspic"">" & Chr(13)
			Response.Write "<div class=""pic"">没有推荐图片2</div>" & Chr(13)
			Response.Write "<div class=""txt""></div>" & Chr(13)
			Response.Write "</div>" & Chr(13)
		End IF
		End IF
	End Sub

	Public Sub Recommends_Articles(Quantity,Strlen)
		IF Not CblogObj.IsCaheEmpty("Recommends_Articles") Then
			Set Rs=Conn.Execute("Select Top " & Quantity & " Article_ID,User_ID,Blog_Name,Article_Title From Article,Tb_User Where Tb_User.ID=Article.User_ID And Article_Hid<>1 And [Top]=1 And IsPhoto=0 Order By Article_ID Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "Recommends_Articles",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		Response.Write "<ul class=""hotarticles"">"
		IF CblogObj.IsCaheArr("Recommends_Articles") Then
			For J=0 to Ubound(CblogObj.Cahe("Recommends_Articles"),2)
				A_title=CblogObj.Cahe("Recommends_Articles")(3,J)
				B_title=A_title
				IF Len(A_title)>Strlen Then
					A_title=Left(A_title,Strlen) & ".."
				End IF
				A_BlogName=CblogObj.Cahe("Recommends_Articles")(2,J)
				B_BlogName=Left(A_BlogName,5) & ".."
				Response.Write "<li class=""top"&J+1&""">" & Chr(13)
				Response.Write "<a href="""&CblogObj.GetDir(CblogObj.Cahe("Recommends_Articles")(1,J))&"/Show.asp?/_articleid/"&CblogObj.Cahe("Recommends_Articles")(0,J)&".html"" title="""&B_title&""">" & Chr(13)
				Response.Write A_Title &"</a> 博客：<a href="""&CblogObj.GetDir(CblogObj.Cahe("Recommends_Articles")(1,J))&""" title="""&A_BlogName&""">"&B_BlogName&"</a></li>" & Chr(13)
			Next
		Else
			Response.Write "<li>没有任何推荐文章!</li>"
		End IF
		Response.Write "</ul>"
	End Sub
	
	Public Sub Help(Quantity)
		IF Not CblogObj.IsCaheEmpty("Recommends_Help") Then
			Set Rs=Conn.Execute("Select Top " & Quantity & " ID,Title From Tb_new Order By ID Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "Recommends_Help",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		Response.Write "<ul class=""help"">" & Chr(13)
		IF CblogObj.IsCaheArr("Recommends_Help") Then
			For J=0 to Ubound(CblogObj.Cahe("Recommends_Help"),2)
				Response.Write "<li><a href=""Show.asp?/_annid/"&CblogObj.Cahe("Recommends_Help")(0,J)&".html"">"&CblogObj.Cahe("Recommends_Help")(1,J)&"</a></li>" & Chr(13)
			Next
		Else
			Response.Write "<li>没有帮助信息</li>"
		End IF
		Response.Write "</ul>"
	End Sub
	
	Public Sub Strip(Top,strlen)
		IF Not CblogObj.IsCaheEmpty("strip") Then
			Set Rs=Conn.Execute("Select Top " & Top & " Article_ID,User_ID,Article_Title From Article Where Article_Hid<>1 And [Top]=2 Order By Article_ID Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "strip",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		Response.Write "<div id=""strip"">" & Chr(13)
		'rESPONSE.WRITE Ubound(CblogObj.Cahe("strip"),2)
		IF CblogObj.IsCaheArr("strip") Then
			For J=0 to Ubound(CblogObj.Cahe("strip"),2)
			A_title=CblogObj.Cahe("strip")(2,J)
			B_title=A_title
			IF Len(A_title)>strlen Then
				A_title=Left(A_title,Strlen) & ".."
			End IF
				IF J=0 Then
					Response.Write "<h1><a href="""& CblogObj.GetDir(CblogObj.Cahe("strip")(1,J)) &"/Show.asp?/_articleid/"& CblogObj.Cahe("strip")(0,J) &".html"" title="""& B_title &""">"& A_title &"</a></h1>" & Chr(13)
				Else
					Response.Write "<h2><a href="""& CblogObj.GetDir(CblogObj.Cahe("strip")(1,J)) &"/Show.asp?/_articleid/"& CblogObj.Cahe("strip")(0,J) &".html"" title="""& B_title &""">"& A_title &"</a></h2>" & Chr(13)
				End IF
			Next
		Else
			Response.Write "<h1>没有头条日志</h1>"
		End IF
		Response.Write "</div>"
	End Sub

	Public Sub New_Articles(Quantity,Strlen)
		IF Not CblogObj.IsCaheEmpty("New_Articles") Then
			Set Rs=Conn.Execute("Select Top " & Quantity & " Article_ID,User_ID,Blog_Name,Article_Title From Article,Tb_User Where Tb_User.ID=Article.User_ID And Article_Hid<>1 And IsPhoto=0 Order By Article_ID Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "New_Articles",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		
		IF CblogObj.IsCaheArr("New_Articles") Then
			For J=0 to Ubound(CblogObj.Cahe("New_Articles"),2)
				A_title=CblogObj.Cahe("New_Articles")(3,J)
				B_title=A_title
				IF Len(A_title)>Strlen Then
					A_title=Left(A_title,Strlen) & ".."
				End IF
				A_BlogName=CblogObj.Cahe("New_Articles")(2,J)
				B_BlogName=Left(A_BlogName,5) & ".."
				Response.Write "<li class=""Articlelist"">" & Chr(13)
				Response.Write "<a href="""&CblogObj.GetDir(CblogObj.Cahe("New_Articles")(1,J))&"/Show.asp?/_articleid/"&CblogObj.Cahe("New_Articles")(0,J)&".html"" title="""&B_title&""">"
				Response.Write A_Title &"</a> 博客：<a href="""&CblogObj.GetDir(CblogObj.Cahe("New_Articles")(1,J))&""" title="""&A_BlogName&""">"&B_BlogName&"</a></li>" & Chr(13)
			Next
		Else
			Response.Write "<li class=""Articlelist"">没有任何日志!</li>"
		End IF
	End Sub
	
	Public Sub Hot_Articles(Quantity,Strlen)
		IF Not CblogObj.IsCaheEmpty("Hot_Articles") Then
			Set Rs=Conn.Execute("Select Top " & Quantity & " Article_ID,User_ID,Blog_Name,Article_Title,Re_Count From Article,Tb_User Where Tb_User.ID=Article.User_ID And Article_Hid<>1 And IsPhoto=0 Order By Re_Count Desc,Article_ID Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "Hot_Articles",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		
		IF CblogObj.IsCaheArr("Hot_Articles") Then
			For J=0 to Ubound(CblogObj.Cahe("Hot_Articles"),2)
				A_title=CblogObj.Cahe("Hot_Articles")(3,J)
				B_title=A_title
				IF Len(A_title)>Strlen Then
					A_title=Left(A_title,Strlen) & ".."
				End IF
				A_BlogName=CblogObj.Cahe("Hot_Articles")(2,J)
				B_BlogName=Left(A_BlogName,5) & ".."
				Response.Write "<li class=""Articlelist"">" & Chr(13)
				Response.Write "<a href="""&CblogObj.GetDir(CblogObj.Cahe("Hot_Articles")(1,J))&"/Show.asp?/_articleid/"&CblogObj.Cahe("Hot_Articles")(0,J)&".html"" title="""&B_title&""">"
				Response.Write A_Title &"</a>("&CblogObj.Cahe("Hot_Articles")(4,J)&") 来自：<a href="""&CblogObj.GetDir(CblogObj.Cahe("Hot_Articles")(1,J))&""" title="""&A_BlogName&""">"&B_BlogName&"</a></li>" & Chr(13)
			Next
		Else
			Response.Write "<li class=""Articlelist"">没有任何日志!</li>"
		End IF
	End Sub
	
	Public Sub Top_Articles(Quantity,Strlen)
		'月:m,年:Y,周:w,季:q可以分别调整成上月,上年,上周,上季
		IF DateDiff("d",CblogObj.Cahe("Top_Articles_Date"),date)>2 Then
			CblogObj.DelCahe("Top_Articles_Date|Top_Articles")
		End IF
		IF Not CblogObj.IsCaheEmpty("Top_Articles") Then
			Set Rs=Conn.Execute("Select Top " & Quantity & " Article_ID,User_ID,User_Name,Article_Title,See_Count From Article Where Article_Hid<>1 And IsPhoto=0 And DateDiff('d',Article_Time,'"&DATE&"')=0 Order By See_Count Desc,Article_ID Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "Top_Articles",Rs.GetRows()
				CblogObj.AddCahe "Top_Articles_Date",date
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		
		IF CblogObj.IsCaheArr("Top_Articles") Then
			Response.Write "<ul id=""Articletop"">" & Chr(13)
			For J=0 to Ubound(CblogObj.Cahe("Top_Articles"),2)
				A_title=CblogObj.Cahe("Top_Articles")(3,J)
				B_title=A_title
				IF Len(A_title)>Strlen Then
					A_title=Left(A_title,Strlen) & ".."
				End IF
				A_BlogName=CblogObj.Cahe("Top_Articles")(2,J)
				B_BlogName=Left(A_BlogName,5) & ".."
				Response.Write "<li id=""articletop"&J+1&""">" & Chr(13)
				Response.Write "<a href="""&CblogObj.GetDir(CblogObj.Cahe("Top_Articles")(1,J))&"/Show.asp?/_articleid/"&CblogObj.Cahe("Top_Articles")(0,J)&".html"" title="""&B_title&""">"
				Response.Write A_Title &"</a>("&CblogObj.Cahe("Top_Articles")(4,J)&") <a href="""&CblogObj.GetDir(CblogObj.Cahe("Top_Articles")(1,J))&""" title="""&A_BlogName&""">"&B_BlogName&"</a></li>" & Chr(13)
			Next
		Else
			Response.Write "<li>没有任何日志!</li>"
		End IF
		Response.Write "</ul>" & Chr(13)
	End Sub
	
	Public Sub New_Photo(Quantity)
		IF Not CblogObj.IsCaheEmpty("New_Photo") Then
			Set Rs=Conn.Execute("Select Top " & Quantity & " Article_ID,User_ID,Article_Title,Photo From Article Where Article_Hid<>1 And Article_Hid<>3 And IsPhoto=1 And Photo<>'' Order By Article_ID Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "New_Photo",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		
		IF CblogObj.IsCaheArr("New_Photo") Then
			For J=0 to Ubound(CblogObj.Cahe("New_Photo"),2)
				A_title=Left(CblogObj.Cahe("New_Photo")(2,J),10)
				B_title=CblogObj.Cahe("New_Photo")(3,J)
				A_BlogName=CblogObj.GetDir(CblogObj.Cahe("New_Photo")(1,J))
				B_BlogName=CblogObj.Cahe("New_Photo")(0,J)
				Response.Write "<div class=""photo""><div><a href="""&A_BlogName&"/Show.asp?/_articleid/"& B_BlogName &".html""><img src="""&B_title&""" border=""0"" width=""260"" alt="""" /></a></div>"
				Response.Write "<p><a href="""&A_BlogName&"/Show.asp?/_articleid/"& B_BlogName &".html"">"&A_title&"</a></p></div>" & Chr(13)
			Next
		Else
			Response.Write "<div class=""photo"">没有任何相片!</div>" & Chr(13)
		End IF
	End Sub

	Public Sub Article_ByClass(Quantity,Strlen)
		IF Not CblogObj.IsCaheEmpty("Class") Then
			Set Rs=Conn.Execute("Select ClassCode,ClassName From Tb_Sys_Class Where ISDEF=1 Order By ClassCode")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "Class",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		IF CblogObj.IsCaheArr("Class") Then
			For J=0 to Ubound(CblogObj.Cahe("Class"),2)
				Response.Write "<div class=""ClassArticlesTitle"">" & Chr(13)
				Response.Write "<h1>"&CblogObj.Cahe("Class")(1,j)&" <a href=""Articleslist.asp?/_classcode/"&CblogObj.Cahe("Class")(0,j)&".html""><img src="""&CityBlogDir&"img/index_100.gif"" border=""0"" alt=""更多"" /></a></h1>" & Chr(13)
				Response.Write "<ul class=""classarticles"">" & Chr(13)
				B_BlogName="Article_ByClass" & CblogObj.Cahe("Class")(0,j)
				IF Not CblogObj.IsCaheEmpty(B_BlogName) Then
					Set Rs=Conn.Execute("Select Top " & Quantity & " Article_ID,User_ID,Article_Title From Article Where Article_Hid<>1 And Article_Code='" & CblogObj.Cahe("Class")(0,j) & "'Order By Article_ID Desc")
					SqlCount=SqlCount+1
					IF NOT RS.EOF Then
						CblogObj.AddCahe B_BlogName,Rs.GetRows()
					End IF
					Rs.Close:Set Rs=Nothing
				End IF
				IF CblogObj.IsCaheArr(B_BlogName) Then
					For I=0 to Ubound(CblogObj.Cahe(B_BlogName),2)
						A_title=CblogObj.GetDir(CblogObj.Cahe(B_BlogName)(1,I)) & "/Show.asp?/_articleid/"& CblogObj.Cahe(B_BlogName)(0,I) &".html"
						B_title=CblogObj.Cahe(B_BlogName)(2,I)
						IF Len(B_title)>Strlen Then
							B_title=left(B_title,Strlen) & ".." 
						End IF
						Response.Write "<li><a href="""& A_title &""" title="""& CblogObj.Cahe(B_BlogName)(2,I) &""">"& B_title &"</a></li>" & Chr(13)
					Next
				Else
					Response.Write "<li>此分类下没有日志</li>"
				End IF
				Response.Write "</ul></div>" & Chr(13)
			Next
		End IF
	End Sub

	Public Sub New_User(Quantity)
		IF Not CblogObj.IsCaheEmpty("New_User") Then
			Set Rs=Conn.Execute("Select Top " & Quantity & " ID,User_Name,Blog_Name,User_Date From Tb_User Order By ID Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "New_User",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		IF CblogObj.IsCaheArr("New_User") Then
			For J=0 to Ubound(CblogObj.Cahe("New_User"),2)
				A_BlogName=CblogObj.GetDir(CblogObj.Cahe("New_User")(0,J))
				B_BlogName=CblogObj.Cahe("New_User")(1,J)
				A_title=CblogObj.Cahe("New_User")(2,J)
				Response.Write "<li class=""Articlelist""><a href="""&A_BlogName&""">"&A_title&"</a> 时间:"& CblogObj.Cahe("New_User")(3,J) &" 创建人: <a href="""&A_BlogName&""">"& B_BlogName &"</a></li>" & Chr(13)
			Next
		Else
			Response.Write "<li class=""Articlelist"">没有任何博客!</li>" & Chr(13)
		End IF
	End Sub

	Public Sub PostCountTop(Quantity)
		Response.Write "<ul class=""blogtop"">" & Chr(13)
		IF Not CblogObj.IsCaheEmpty("PostCountTop") Then
			Set Rs=Conn.Execute("Select Top " & Quantity & "  Count(Article_ID),User_ID,Max(Tb_User.Blog_Name) From Article,Tb_User Where Article.User_ID=Tb_User.ID Group By Article.User_Name,User_ID Order By Count(Article_ID) Desc,Max(Article_ID) Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "PostCountTop",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		IF CblogObj.IsCaheArr("PostCountTop") Then
			For J=0 to Ubound(CblogObj.Cahe("PostCountTop"),2)
				A_Title=CblogObj.GetDir(CblogObj.Cahe("PostCountTop")(1,j))
				Response.Write "<li class=""blogtop"&J+1&"""><a href="""& A_Title &""">"& CblogObj.Cahe("PostCountTop")(2,j) &"</a> ("&CblogObj.Cahe("PostCountTop")(0,j)&")</li>" & Chr(13)
			Next
		Else
			Response.Write "<li>没有人发过贴</li>"
		End IF
		Response.Write "</ul>" & Chr(13)
	End Sub

	Public Sub BuLuoCountTop()
		Response.Write "<ul class=""blogtop"">" & Chr(13)
		IF Not CblogObj.IsCaheEmpty("BuLuoCountTop") Then
			Set Rs=Conn.Execute("Select Top 10 Max(UID),Count(Article_ID),Article_Bl,Max(Tb_User.User_Name) From Article,Tb_BuoLuo,Tb_User Where Article.Article_Bl=Tb_BuoLuo.ClassName And Tb_BuoLuo.Bid=0 And Tb_User.ID=Uid Group By Article_Bl Order By Count(Article_ID) Desc,Article_Bl")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "BuLuoCountTop",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		IF CblogObj.IsCaheArr("BuLuoCountTop") Then
			For J=0 to Ubound(CblogObj.Cahe("BuLuoCountTop"),2)
				A_Title=CblogObj.GetDir(CblogObj.Cahe("BuLuoCountTop")(0,j))
				Response.Write "<li class=""blogtop"&J+1&"""><a href="""& A_Title &"/Buluo.asp"">"& CblogObj.Cahe("BuLuoCountTop")(2,j) &"</a> ("&CblogObj.Cahe("BuLuoCountTop")(1,j)&") 酋长:<a href="""& A_Title &""">"& CblogObj.Cahe("BuLuoCountTop")(3,j) &"</a></li>" & Chr(13)
			Next
		Else
			Response.Write "<li>没有部落</li>"
		End IF
		Response.Write "</ul>" & Chr(13)
	End Sub

	Public Sub ClassList(PageShow)
		Response.Write "<ul class=""byclass"">" & Chr(13)
		IF Not CblogObj.IsCaheEmpty("ClassCodelist") Then
			Set Rs=Conn.Execute("select ClassCode,ClassName FROM TB_SYS_CLASS ORDER BY CLASSCODE")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "ClassCodelist",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		IF CblogObj.IsCaheArr("ClassCodelist") Then
			For J=0 to Ubound(CblogObj.Cahe("ClassCodelist"),2)
				A_Title=CblogObj.Cahe("ClassCodelist")(1,j)
				Response.Write "<li><a href="""& PageShow &"?/_ClassCode/"& CblogObj.Cahe("ClassCodelist")(0,j) &".html"">"& A_Title &"</a></li>" & Chr(13)
			Next
		Else
			Response.Write "<li>没有分类</li>"
		End IF
		Response.Write "</ul>" & Chr(13)
	End Sub

	Public Sub Recommends_Blog(Quantity)
		Response.Write "<ul class=""blogtop"">" & Chr(13)
		IF Not CblogObj.IsCaheEmpty("Recommends_Blog") Then
			Set Rs=Conn.Execute("Select Top "& Quantity &" ID,User_Name,Blog_Name From Tb_User Where Blog_Top=1 Order By Id Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "Recommends_Blog",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		IF CblogObj.IsCaheArr("Recommends_Blog") Then
			For J=0 to Ubound(CblogObj.Cahe("Recommends_Blog"),2)
				A_Title=CblogObj.GetDir(CblogObj.Cahe("Recommends_Blog")(0,j))
				Response.Write "<li class=""Recommends_Blog"&J+1&"""><a href="""& A_Title &""">"& CblogObj.Cahe("Recommends_Blog")(2,j) &"</a> 创建人:"&CblogObj.Cahe("Recommends_Blog")(1,j)&"</li>" & Chr(13)
			Next
		Else
			Response.Write "<li>没有推荐用户</li>"
		End IF
		Response.Write "</ul>" & Chr(13)
	End Sub
	Public Sub Recommends_User(Quantity)
		Response.Write "<ul class=""blogtop"">" & Chr(13)
		IF Not CblogObj.IsCaheEmpty("Recommends_User") Then
			Set Rs=Conn.Execute("Select Top "& Quantity &" ID,User_Name From Tb_User Where Blog_Top=2 Order By Id Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "Recommends_User",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		IF CblogObj.IsCaheArr("Recommends_User") Then
			For J=0 to Ubound(CblogObj.Cahe("Recommends_User"),2)
				A_Title=CblogObj.GetDir(CblogObj.Cahe("Recommends_User")(0,j))
				Response.Write "<li class=""Recommends_Blog"&J+1&""">作者:<a href="""& A_Title &""">"& CblogObj.Cahe("Recommends_User")(1,j) &"</a></li>" & Chr(13)
			Next
		Else
			Response.Write "<li>没有专栏作者</li>"
		End IF
		Response.Write "</ul>" & Chr(13)
	End Sub

	Public Sub Counts()
		IF Not CblogObj.IsCaheEmpty("Counts") Then
			Set Rs=Conn.Execute("Select (Select Count(id) From Tb_User),(Select Count(Article_ID) From Article),(Select Count(ID) From Tb_BuoLuo Where Bid=0),(Select Count(Reply_ID) From Tb_Reply),(Select Count(Article_ID) From Article Where DateDiff('D',Article_Time,'"&DATE&"')=0),(Select Count(ID) From TrackBack),(Select Count(ID) From Tb_User Where DateDiff('D',User_Date,'"&DATE&"')=0),(Select Count(Reply_ID) From Tb_Reply Where DateDiff('D',Reply_Time,'"&DATE&"')=0) From Tb_User")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "Counts",Rs.GetRows()
				CblogObj.AddCaheDate "Counts",Now()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		IF CblogObj.IsCaheArr("Counts") Then
			Response.Write "<ul id=""counts"">" & Chr(13)
			Response.Write "<li>注册用户:" & CblogObj.Cahe("Counts")(0,0) & "</li>" & Chr(13)
			Response.Write "<li>日志总数:" & CblogObj.Cahe("Counts")(1,0) & "</li>" & Chr(13)
			Response.Write "<li>共有部落:" & CblogObj.Cahe("Counts")(2,0) & "</li>" & Chr(13)
			Response.Write "<li>发表评论:" & CblogObj.Cahe("Counts")(3,0) & "</li>" & Chr(13)
			Response.Write "<li>引用通告:" & CblogObj.Cahe("Counts")(5,0) & "</li>" & Chr(13)
			Response.Write "<li>今日信息:" & CblogObj.Cahe("Counts")(4,0)+CblogObj.Cahe("Counts")(6,0)+CblogObj.Cahe("Counts")(7,0) & "</li>" & Chr(13)
			
			
			
			Response.Write "</ul>" & Chr(13)
		End IF
	End Sub

	Public Sub AnnouncementList(UserPageSize)
		Response.Write "<ul id=""Announcement"">"
		Dim ArticleArr,RsCount,iii
		Set Rs = Server.CreateObject("Adodb.RecordSet")
		Rs.open "Select ID,Title,time From Tb_New Order BY id Desc",Conn, 1, 1
		SqlCount=SqlCount+1
		If Not Rs.Eof Then
			Rs.PageSize = UserPageSize
			MaxP=rs.PageCount
			Rs.AbsolutePage=CblogObj.QueryPage
			RsCount=Rs.RecordCount
			ArticleArr = Rs.GetRows(UserPageSize)
			Rs.Close:Set Rs=nothing
			for iii=0 to Ubound(ArticleArr,2)
				Response.Write "<li><a href=""show.asp?/_annid/"&ArticleArr(0,iii)&".html"">"& ArticleArr(1,iii) &"</a> <span>时间:"& ArticleArr(2,iii) &"</span></li>" & Chr(13)
			Next
			ArticleArr=Empty
		Else
			Rs.Close:Set Rs=nothing
			Response.Write "<li>"
			Response.Write "没有任何公告"
			Response.Write "</li>"
		End IF
		Response.Write "</ul>"
		CblogObj.PageList RsCount,CblogObj.QueryPage,UserPageSize,20,False
	End Sub
	
	Public Sub ArticlesList(UserPageSize)
		Response.Write "<ul id=""Announcement"">"
		Dim ArticleArr,RsCount,iii
		Set Rs = Server.CreateObject("Adodb.RecordSet")
		IF CblogObj.QueryStringPage("title",True)<>"" Then
			Rs.open "Select Article_ID,User_ID,User_Name,Article_Title From Article Where Article_Hid<>1 And Article_Title Like '%" & CblogObj.QueryStringPage("title",True) & "%' Order By Article_ID Desc",Conn, 1, 1
		Else
			IF CblogObj.QueryStringPage("username",True)<>"" Then
				Rs.open "Select Article_ID,User_ID,User_Name,Article_Title From Article Where Article_Hid<>1 And User_Name Like '%"& CblogObj.QueryStringPage("username",True) &"%' Order By Article_ID Desc",Conn, 1, 1
			Else
				IF CblogObj.QueryStringPage("classcode",True)<>"" Then
					Rs.open "Select Article_ID,User_ID,User_Name,Article_Title From Article Where Article_Hid<>1 And Article_Code Like '"& CblogObj.QueryStringPage("classcode",True) &"%' Order By Article_ID Desc",Conn, 1, 1
				Else
					Rs.open "Select Article_ID,User_ID,User_Name,Article_Title From Article Where Article_Hid<>1 Order By Article_ID Desc",Conn, 1, 1
				End IF
			End IF
		End IF
		SqlCount=SqlCount+1
		If Not Rs.Eof Then
			Rs.PageSize = UserPageSize
			MaxP=rs.PageCount
			Rs.AbsolutePage=CblogObj.QueryPage
			RsCount=Rs.RecordCount
			ArticleArr = Rs.GetRows(UserPageSize)
			Rs.Close:Set Rs=nothing
			For iii=0 to Ubound(ArticleArr,2)
				Response.Write "<li><a href="""&CblogObj.GetDir(ArticleArr(1,iii))&"/show.asp?/_articleid/"&ArticleArr(0,iii)&".html"">"& ArticleArr(3,iii) &"</a> <span>作者:"& ArticleArr(2,iii) &"</span></li>" & Chr(13)
			Next
			ArticleArr=Empty
		Else
			Rs.Close:Set Rs=nothing
			Response.Write "<li>"
			Response.Write "没有任何日志"
			Response.Write "</li>"
		End IF
		Response.Write "</ul>"
		CblogObj.PageList RsCount,CblogObj.QueryPage,UserPageSize,20,False
	End Sub
	
	Public Sub BlogList(UserPageSize)
		Response.Write "<ul id=""Announcement"">"
		Dim ArticleArr,RsCount,iii,Title
		Set Rs = Server.CreateObject("Adodb.RecordSet")
		IF CblogObj.QueryStringPage("ClassCode",True)<>"" And Isnumeric(CblogObj.QueryStringPage("ClassCode",True)) Then
			Rs.open "Select ID,User_Name,Blog_Name,User_Date,Blog_Caty,Blog_Info,Blog_Title From Tb_User Where Blog_class Like '" & CblogObj.QueryStringPage("ClassCode",True) & "%' Order By ID Desc",Conn, 1, 1
		Else
			IF CblogObj.QueryStringPage("blogname",True)<>"" Then
				Rs.open "Select ID,User_Name,Blog_Name,User_Date,Blog_Caty,Blog_Info,Blog_Title From Tb_User Where Blog_Name Like '%" & CblogObj.QueryStringPage("blogname",True) & "%' Order By ID Desc",Conn, 1, 1
			Else
				Rs.open "Select ID,User_Name,Blog_Name,User_Date,Blog_Caty,Blog_Info,Blog_Title From Tb_User Order By ID Desc",Conn, 1, 1
			End IF
		End IF
		SqlCount=SqlCount+1
		If Not Rs.Eof Then
			Rs.PageSize = UserPageSize
			MaxP=rs.PageCount
			Rs.AbsolutePage=CblogObj.QueryPage
			RsCount=Rs.RecordCount
			ArticleArr = Rs.GetRows(UserPageSize)
			Rs.Close:Set Rs=nothing
			For iii=0 to Ubound(ArticleArr,2)
				Title=Replace(ArticleArr(5,iii),"<br/>",chr(10))
				Title=Replace(Title,chr(10)&chr(10),chr(10))
				Response.Write "<li><a href="""&CblogObj.GetDir(ArticleArr(0,iii))&""" title=""名称:"&ArticleArr(6,iii)& Chr(10) & "简介:" & Chr(10) & Title &""">"& ArticleArr(2,iii) &"</a> <span>创建人:"& ArticleArr(1,iii) &"</span> <span>城市:"& ArticleArr(4,iii) &"</span> <span>日期:"& ArticleArr(3,iii) &"</span> </li>" & Chr(13)
			Next
			ArticleArr=Empty
		Else
			Rs.Close:Set Rs=nothing
			Response.Write "<li>"
			Response.Write "没有任何博客用户"
			Response.Write "</li>"
		End IF
		Response.Write "</ul>"
		CblogObj.PageList RsCount,CblogObj.QueryPage,UserPageSize,20,False
	End Sub
	Public Sub BlogTopList(UserPageSize)
		Response.Write "<ul id=""Announcement"">"
		Dim ArticleArr,RsCount,iii,Title
		Set Rs = Server.CreateObject("Adodb.RecordSet")
		Rs.Open "Select Top 100 Count(Article_ID),User_ID,Max(Tb_User.Blog_Name),Max(Tb_User.User_Name) From Article,Tb_User Where Article.User_ID=Tb_User.ID  Group By Article.User_Name,User_ID Order By Count(Article_ID) Desc",Conn, 1, 1
		SqlCount=SqlCount+1
		If Not Rs.Eof Then
			Rs.PageSize = UserPageSize
			MaxP=rs.PageCount
			Rs.AbsolutePage=CblogObj.QueryPage
			RsCount=Rs.RecordCount
			ArticleArr = Rs.GetRows(UserPageSize)
			Rs.Close:Set Rs=nothing
			For iii=0 to Ubound(ArticleArr,2)
				Response.Write "<li><a href="""&CblogObj.GetDir(ArticleArr(1,iii))&""">"& ArticleArr(2,iii) &"</a> <span>创建人:"& ArticleArr(3,iii) &"</span> <span>共有发表日志:"& ArticleArr(0,iii) &" 篇</span> </li>" & Chr(13)
			Next
			ArticleArr=Empty
		Else
			Rs.Close:Set Rs=nothing
			Response.Write "<li>"
			Response.Write "没有任何博客用户"
			Response.Write "</li>"
		End IF
		Response.Write "</ul>"
		CblogObj.PageList RsCount,CblogObj.QueryPage,UserPageSize,20,False
	End Sub

	Public Sub PhotoTop(Quantity,Strlen)
		IF Not CblogObj.IsCaheEmpty("PhotoTop") Then
			Set Rs=Conn.Execute("Select Top "& Quantity &" Article_ID,User_ID,Article_Title From Article Where IsPhoto=1 Order By See_Count Desc,Article_ID Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "PhotoTop",Rs.GetRows()
				CblogObj.AddCaheDate "PhotoTop",Now()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		
		Response.Write "<ul class=""PhotoTop"">"
		IF CblogObj.IsCaheArr("PhotoTop") Then
			For J=0 to Ubound(CblogObj.Cahe("PhotoTop"),2)
				A_title=CblogObj.Cahe("PhotoTop")(2,J)
				B_title=A_title
				IF Len(A_title)>Strlen Then
					A_title=Left(A_title,Strlen) & ".."
				End IF
				Response.Write "<li><a href="""&CblogObj.GetDir(CblogObj.Cahe("PhotoTop")(1,J))&"/Show.asp?/_articleid/"&CblogObj.Cahe("PhotoTop")(0,J)&".html"" title="""&B_title&""">" & A_Title &"</a></li>" & Chr(13)
			Next
		Else
			Response.Write "<li>没有任何相册!</li>"
		End IF
		Response.Write "</ul>"
	End Sub
	
	Public Sub PhotoList(UserPageSize,Strlen)
		Dim ArticleArr,RsCount,iii,Title
		Set Rs = Server.CreateObject("Adodb.RecordSet")
		Rs.open "Select Article_ID,User_ID,Article_Title,Photo From Article Where Article_Hid<>1 And Photo<>'' And IsPhoto=1 Order By Article_ID Desc",Conn, 1, 1
		SqlCount=SqlCount+1
		If Not Rs.Eof Then
			Rs.PageSize = UserPageSize
			MaxP=rs.PageCount
			Rs.AbsolutePage=CblogObj.QueryPage
			RsCount=Rs.RecordCount
			ArticleArr = Rs.GetRows(UserPageSize)
			Rs.Close:Set Rs=nothing
			For iii=0 to Ubound(ArticleArr,2)
				A_Title=ArticleArr(2,iii)
				IF Len(A_Title)>Strlen Then
					A_Title=lEFT(A_Title,Strlen) & ".."
				End IF
				Response.Write "<div class=""photo""><div><a href="""&CblogObj.GetDir(ArticleArr(1,iii))&"/Show.asp?/_articleid/"& ArticleArr(0,iii) &".html"">"
				Response.Write "<img src="""& ArticleArr(3,iii) &""" border=""0"" width=""190"" alt="""" /></a></div><p><a href="""&CblogObj.GetDir(ArticleArr(1,iii))&"/Show.asp?/_articleid/"&  ArticleArr(0,iii)  &".html"">"& A_Title &"</a></p></div>" & Chr(13)
			Next
			ArticleArr=Empty
		End IF
		CblogObj.PageList RsCount,CblogObj.QueryPage,UserPageSize,20,False
	End Sub
	
	Public Sub AnnShow()
	Response.Write "<script language=""JavaScript"" src=""inc/common.js"" type=""text/javascript""></script>"
	Dim ArticleID,Show,Title,Info,Times
	ArticleID=CblogObj.IsCInt(CblogObj.QueryStringPage("annid",True))
	Set Rs=Conn.Execute("Select Title,Info,[Time] From Tb_New where Id="& ArticleID &"")
	IF Not Rs.Eof Then
		Show=Rs.GetRows() 
		Title=Show(0,0)
		Info=UBBCode(Show(1,0))
		Times=Show(2,0)
		Show=Empty
	End IF
	Rs.Close:Set Rs=Nothing
	Response.Write "<h3>"& Title &" <u>时间:"& Times &"</u></h3>"
	Response.Write "<p>"& Info &" </p>"
	End Sub
	
	Public Sub TagTop(Quantity)
		IF Not CblogObj.IsCaheEmpty("TagTop") Then
			Set Rs=Conn.Execute("Select Top "& Quantity &" Tag,TagCount From Tag Order By TagCount Desc,ID Desc")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "TagTop",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		
		Response.Write "<ul class=""byclass"">" & Chr(13)
		IF CblogObj.IsCaheArr("TagTop") Then
			For J=0 to Ubound(CblogObj.Cahe("TagTop"),2)
				Response.Write "<li><a href=""Tag.asp?Tag="& CblogObj.Cahe("TagTop")(0,j) &"&amp;"">" & CblogObj.Cahe("TagTop")(0,j) &"</a>("& CblogObj.Cahe("TagTop")(1,j) &")</li>" & Chr(13)
			Next
		Else
			Response.Write "<li>没有任何TAG</li>"
		End IF
		Response.Write "</ul>"
	End Sub
	
	Public Sub TagList(UserPageSize)
		Response.Write "<script language=""JavaScript"" src=""inc/common.js"" type=""text/javascript""></script>"
		Response.Write "<ul id=""Announcement"">"
		Dim ArticleArr,RsCount,iii,Tag
		Tag=CblogObj.GetRequest("Tag")
		Set Rs = Server.CreateObject("Adodb.RecordSet")
		Rs.open "Select Article_ID,User_ID,User_Name,Article_Title,Article_Tag From Article Where Article_Hid<>1 And Article_Tag Like '%" & Tag & "%' Order By Article_ID Desc",Conn, 1, 1
		SqlCount=SqlCount+1
		If Not Rs.Eof Then
			Rs.PageSize = UserPageSize
			MaxP=rs.PageCount
			Rs.AbsolutePage=CblogObj.QueryPage
			RsCount=Rs.RecordCount
			ArticleArr = Rs.GetRows(UserPageSize)
			Rs.Close:Set Rs=nothing
			For iii=0 to Ubound(ArticleArr,2)
				Response.Write "<li><a href="""&CblogObj.GetDir(ArticleArr(1,iii))&"/show.asp?/_articleid/"&ArticleArr(0,iii)&".html"">"& ArticleArr(3,iii) &"</a> <span>作者:"& ArticleArr(2,iii) &" Tag:"& CblogObj.TagUbb(ArticleArr(4,iii),"tag.asp") &"</span></li>" & Chr(13)
			Next
			ArticleArr=Empty
		Else
			Rs.Close:Set Rs=nothing
			Response.Write "<li>"
			Response.Write "没有任何日志"
			Response.Write "</li>"
		End IF
		Response.Write "</ul>"
		CblogObj.PageList RsCount,CblogObj.QueryPage,UserPageSize,20,False
	End Sub
	
	
	Public Sub BuluoTop()
		Response.Write "<ul class=""PhotoTop"">" & Chr(13)
		IF Not CblogObj.IsCaheEmpty("BuLuoCountTop") Then
			Set Rs=Conn.Execute("Select Top 10 Max(UID),Count(Article_ID),Article_Bl,Max(Tb_User.User_Name) From Article,Tb_BuoLuo,Tb_User Where Article.Article_Bl=Tb_BuoLuo.ClassName And Tb_BuoLuo.Bid=0 And Tb_User.ID=Uid Group By Article_Bl Order By Count(Article_ID) Desc,Article_Bl")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "BuLuoCountTop",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		IF CblogObj.IsCaheArr("BuLuoCountTop") Then
			For J=0 to Ubound(CblogObj.Cahe("BuLuoCountTop"),2)
				A_Title=CblogObj.GetDir(CblogObj.Cahe("BuLuoCountTop")(0,j))
				Response.Write "<li><a href="""& A_Title &"/Buluo.asp"">"& CblogObj.Cahe("BuLuoCountTop")(2,j) &"</a> ("&CblogObj.Cahe("BuLuoCountTop")(1,j)&") 酋长:<a href="""& A_Title &""">"& CblogObj.Cahe("BuLuoCountTop")(3,j) &"</a></li>" & Chr(13)
			Next
		Else
			Response.Write "<li>没有部落</li>"
		End IF
		Response.Write "</ul>" & Chr(13)
	End Sub
	
	
	Public Sub BuluoList(UserPageSize)
		Response.Write "<script language=""JavaScript"" src=""inc/common.js"" type=""text/javascript""></script>"
		Response.Write "<ul id=""Announcement"">"
		Dim ArticleArr,RsCount,iii,Tag
		Set Rs = Server.CreateObject("Adodb.RecordSet")
		IF CblogObj.QueryStringPage("ClassCode",True)<>"" And Isnumeric(CblogObj.QueryStringPage("ClassCode",True)) Then
			Rs.open "Select ID,UID,ClassName,(Select Count(*) From Article Where Article_Bl=Tb_BuoLuo.ClassName),(Select Count(ID) From Tb_BuoLuo As B Where B.ClassName=Tb_BuoLuo.ClassName),(Select User_Name From Tb_User Where ID=Tb_BuoLuo.Uid) From Tb_BuoLuo where Bid=0 And ClassCode Like '"& CblogObj.QueryStringPage("ClassCode",True) &"%' Order By Id Desc",Conn, 1, 1
		Else
			Rs.open "Select ID,UID,ClassName,(Select Count(*) From Article Where Article_Bl=Tb_BuoLuo.ClassName),(Select Count(ID) From Tb_BuoLuo As B Where B.ClassName=Tb_BuoLuo.ClassName),(Select User_Name From Tb_User Where ID=Tb_BuoLuo.Uid) From Tb_BuoLuo where Bid=0 Order By Id Desc",Conn, 1, 1
		End IF
		SqlCount=SqlCount+1
		If Not Rs.Eof Then
			Rs.PageSize = UserPageSize
			MaxP=rs.PageCount
			Rs.AbsolutePage=CblogObj.QueryPage
			RsCount=Rs.RecordCount
			ArticleArr = Rs.GetRows(UserPageSize)
			Rs.Close:Set Rs=nothing
			For iii=0 to Ubound(ArticleArr,2)
				Response.Write "<li><span>部落名称:</span><a href="""&CblogObj.GetDir(ArticleArr(1,iii))&"/BuLuo.asp"">"& ArticleArr(2,iii) &"</a> <span>酋长:<a href="""& CblogObj.GetDir(ArticleArr(1,iii)) &""">"& ArticleArr(5,iii) &"</a> 成员:"& ArticleArr(4,iii) &" 文章: " & ArticleArr(3,iii) & "〖<a href=""UserManage/Article_GroupByAddBl.Asp?ClassID="& ArticleArr(0,iii) &"&Action=add"">加入</a>〗</span></li>" & Chr(13)
			Next
			ArticleArr=Empty
		Else
			Rs.Close:Set Rs=nothing
			Response.Write "<li>"
			Response.Write "没有任何部落"
			Response.Write "</li>"
		End IF
		Response.Write "</ul>"
		CblogObj.PageList RsCount,CblogObj.QueryPage,UserPageSize,20,False
	End Sub
	
	Public Sub RssClass()
		Response.Write "<ul id=""rssclass"">"
		IF Not CblogObj.IsCaheEmpty("Rss_Class") Then
			Set Rs=Conn.Execute("Select ClassCode,ClassName From Tb_RssClass Order By ClassCode")
			SqlCount=SqlCount+1
			IF NOT RS.EOF Then
				CblogObj.AddCahe "Rss_Class",Rs.GetRows()
			End IF
			Rs.Close:Set Rs=Nothing
		End IF
		IF CblogObj.IsCaheArr("Rss_Class") Then
			For J=0 TO Ubound(CblogObj.Cahe("Rss_Class"),2)
				A_title=CblogObj.Cahe("Rss_Class")(0,J)
				B_title=CblogObj.Cahe("Rss_Class")(1,J)
				IF Len(A_title)=3 Then
					Response.Write "<li class=""rssclasstitle"">"& B_title &"</li>"
				Else
					Response.Write "<li class=""rssclasslist""> <a href=""rssxml.asp?/_classcode/"&A_title&".html"">"& B_title &"</a> </li>"
				End IF
			Next
		Else
			Response.Write "<li>没有任何RSS分类</li>"
		End IF
		Response.Write "</ul>"
	End SUB
	
	Public Sub RssList(UserPageSize)
		Response.Write "<ul id=""Announcement"">"
		Dim ArticleArr,RsCount,iii
		Set Rs = Server.CreateObject("Adodb.RecordSet")
		IF CblogObj.QueryStringPage("classcode",True)<>"" Then
			Rs.open "select ID,Rssname,RssUrl from Tb_Rss Where ClassCode Like '" & CblogObj.QueryStringPage("classcode",True) & "%' Order By ID Desc",Conn, 1, 1
		Else
			IF CblogObj.GetRequest("key")<>"" Then
				Rs.open "select ID,Rssname,RssUrl from Tb_Rss Where Rssname Like '%" & CblogObj.GetRequest("key") & "%' Order By ID Desc",Conn, 1, 1
			Else
				Rs.open "select ID,Rssname,RssUrl from Tb_Rss Order By ID Desc",Conn, 1, 1
			End IF
		End IF
		SqlCount=SqlCount+1
		If Not Rs.Eof Then
			Rs.PageSize = UserPageSize
			MaxP=rs.PageCount
			Rs.AbsolutePage=CblogObj.QueryPage
			RsCount=Rs.RecordCount
			ArticleArr = Rs.GetRows(UserPageSize)
			Rs.Close:Set Rs=nothing
			For iii=0 to Ubound(ArticleArr,2)
				Response.Write "<li><span>名称:</span><a href=""rssshow.asp?Rssurl="&Server.URLEncode(ArticleArr(2,iii))&""">"& ArticleArr(1,iii) &"</a><br/><span>地址:"& ArticleArr(2,iii) &"</span></li>" & Chr(13)
			Next
			ArticleArr=Empty
		Else
			Rs.Close:Set Rs=nothing
			Response.Write "<li>"
			Response.Write "没有RSS频道"
			Response.Write "</li>"
		End IF
		Response.Write "</ul>"
		CblogObj.PageList RsCount,CblogObj.QueryPage,UserPageSize,20,False
	End Sub
	
	
	
	
	
End Class


Dim DefCls
Set DefCls=New DefaultCls

	
%>
