<%
Dim LMT_UrlEndString
Function DisplayAnnouncesSplitPages

	Dim Rs,SQL,Temp,TempArray
	If EFlag = 1 and EID = 0 Then
		'GBL_SiteBottomString = ""
		'Exit Function
	End If

	If EID > 0 Then
		TempArray = Application(DEF_MasterCookies & "BoardInfo" & GBL_board_ID & "_TI")
		If EID = 0 Then EID = cCur(TempArray(0,0))
	Else
		TempArray = Application(DEF_MasterCookies & "BoardInfo" & GBL_board_ID)
	End if

	Dim SQLEndString,WhereFlag
	WhereFlag = 1

	If EID > 0 Then
		SQLEndString = " where GoodAssort=" & EID
	Else
		SQLEndString = " where GoodFlag=1 and boardid=" & GBL_board_ID
	End If

	Dim ALL_Count
	If EID > 0 Then
		ALL_Count = cCur(TempArray(2,EIndex))
		If ALL_Count = 0 Then
			Set Rs = Con.ExeCute("Select Count(*) from LeadBBS_Announce where GoodAssort=" & EID)
			If Rs.Eof Then
				ALL_Count = -1
			Else
				ALL_Count = Rs(0)
				If isNull(ALL_Count) Then ALL_Count = 0
				ALL_Count = cCur(ALL_Count)
				If ALL_Count = 0 Then ALL_Count = -1
			End If
			Rs.Close
			Set Rs = Nothing
			TempArray(2,EIndex) = ALL_Count
			Application.Lock
			Application(DEF_MasterCookies & "BoardInfo" & GBL_board_ID & "_TI") = TempArray
			Application.UnLock
		End If
	Else
		ALL_Count = GBL_Board_GoodNum
	End If

	Dim ALL_FirstRootID,ALL_LastRootID
	If All_Count > 0 Then
		If EID > 0 Then
			ALL_FirstRootID = TempArray(3,EIndex)
			ALL_LastRootID = TempArray(4,EIndex)
		Else
			ALL_FirstRootID = TempArray(33,0)
			ALL_LastRootID = TempArray(34,0)
		End If
		If ALL_FirstRootID = 0 Then
			SQL = "Select Max(ID) from LeadBBS_Announce " & SQLEndString
			Set Rs = Con.ExeCute(SQL)
			GBL_DBNum = GBL_DBNum + 1
			If Not Rs.Eof Then
				ALL_FirstRootID = Rs(0)
				If isNull(ALL_FirstRootID) Then ALL_FirstRootID = 0
				ALL_FirstRootID = cCur(ALL_FirstRootID)
				If EID > 0 Then
					TempArray(3,EIndex) = ALL_FirstRootID
					Application.Lock
					Application(DEF_MasterCookies & "BoardInfo" & GBL_board_ID & "_TI") = TempArray
					Application.UnLock
				Else
					UpdateBoardApplicationInfo GBL_board_ID,ALL_FirstRootID,33
				End If
			Else
				ALL_FirstRootID = 0
			End If
			Rs.Close
			Set Rs = Nothing
		End If
		If ALL_LastRootID = 0 Then
			SQL = "Select Min(ID) from LeadBBS_Announce " & SQLEndString
			Set Rs = Con.ExeCute(SQL)
			GBL_DBNum = GBL_DBNum + 1
			If Not Rs.Eof Then
				ALL_LastRootID = Rs(0)
				If isNull(ALL_LastRootID) Then ALL_LastRootID = 0
				ALL_LastRootID = cCur(ALL_LastRootID)
				If EID > 0 Then
					TempArray(4,EIndex) = ALL_LastRootID
					Application.Lock
					Application(DEF_MasterCookies & "BoardInfo" & GBL_board_ID & "_TI") = TempArray
					Application.UnLock
				Else
					UpdateBoardApplicationInfo GBL_board_ID,ALL_LastRootID,34
				End If
			Else
				ALL_LastRootID = 0
			End If
			Rs.Close
			Set Rs = Nothing
		End If
	Else
		ALL_FirstRootID = 0
		ALL_LastRootID = 0
	End If

	Dim RootID,Temp1,Temp2
	Dim Upflag

	RootID = Left(Request.QueryString("RootID"),14)
	If isNumeric(RootID)=0 Then RootID=0
	RootID = cCur(RootID)

	Dim LastNum,LastNumBak
	LastNum = 0
	
	LastNumBak = (ALL_Count mod DEF_MaxListNum)
	If LastNumBak = 0 Then LastNumBak = DEF_MaxListNum

	Upflag = Request.QueryString("Upflag")
	If Upflag<>"1" and Upflag<>"0" Then Upflag="0"
	If Upflag = "1" Then
		LastNum = Request.QueryString("Num")
		If LastNum <> "" Then
			LastNum = LastNumBak
		End If
	End If

	Dim Page,MaxPage,JMPage
	Page = Left(Request.QueryString("p"),14)
	If isNumeric(Page) = 0 or inStr(Page,".") > 0 Then Page = 0
	Page = cCur(Page)
	MaxPage = Fix(All_Count / DEF_MaxListNum)
	If (All_Count mod DEF_MaxListNum)<>0 Then MaxPage = MaxPage + 1
	MaxPage = MaxPage - 1
	If Page > MaxPage or LastNum > 0 Then
		Page = MaxPage
	End If

	JMPage = Left(Request.QueryString("q"),14)
	If isNumeric(JMPage) = 0 or inStr(JMPage,".") > 0 Then JMPage = 0
	JMPage = Fix(cCur(JMPage))
	If JMPage > DEF_MaxJumpPageNum Then JMPage = 0
	
	Dim JMPRootID
	JMPRootID = Left(Request.QueryString("r"),14)
	If isNumeric(JMPRootID)=0 Then JMPRootID=0
	JMPRootID = Fix(cCur(JMPRootID))
	
	If JMPage > Maxpage or Maxpage < 0 Then JMPage = 0
	If Upflag="0" and JMPage+Page > MaxPage Then JMPage = 0
	If Upflag="1" and JMPage+Page < 0 Then JMPage = 0
	If JMPRootID > ALL_FirstRootID Then JMPage = 0
	If JMPRootID < ALL_LastRootID Then JMPage = 0

	LMT_UrlEndString = "&E=" & EFlag
	If EID > 0 Then LMT_UrlEndString = LMT_UrlEndString & "&EID=" & EID
	If RootID > 0 Then LMT_UrlEndString = LMT_UrlEndString & "&RootID=" & RootID
	If Page > 0 Then LMT_UrlEndString = LMT_UrlEndString & "&p=" & Page	
	If Upflag = "1" Then LMT_UrlEndString = LMT_UrlEndString & "&Upflag=" & Upflag	
	If LastNum <> 0 Then LMT_UrlEndString = LMT_UrlEndString & "&Num=1"
	If JMPage > 0 Then LMT_UrlEndString = LMT_UrlEndString & "&q=" & JMPage
	If JMPRootID > 0 Then LMT_UrlEndString = LMT_UrlEndString & "&r=" & JMPRootID

	If Upflag="1" Then
		Page = Page - JMPage
	Else
		Page = Page + JMPage
	End If

	If Page = 0 Then '开启此项则当页数为0时即忽略一切信息的返回首页
		JMPage = 0
		JMPRootID = 0
		LastNum = 0
		Upflag = "0"
		RootID = 0
	End If

	Dim HaveRootIDFlag
	Dim FirstRootID,LastRootID

	If Temp1+1<DEF_MaxListNum and All_Count > 0 Then
		If Upflag="0" Then
			If JMPage > 0 Then
				If JMPRootID<>0 Then
					If WhereFlag = 1 Then
						SQLEndString = SQLEndString & " And ID<" & JMPRootID
					Else
						SQLEndString = SQLEndString & " Where ID<" & JMPRootID
						WhereFlag = 1
					End If
				End If
			Else
				If RootID<>0 Then
					If WhereFlag = 1 Then
						SQLEndString = SQLEndString & " And ID<" & RootID
					Else
						SQLEndString = SQLEndString & " Where ID<" & RootID
						WhereFlag = 1
					End If
				End If
			End If
		Else
			If JMPage > 0 Then
				If WhereFlag = 1 Then
					SQLEndString = SQLEndString & " And ID>" & JMPRootID
				Else
					SQLEndString = SQLEndString & " Where ID>" & JMPRootID
					WhereFlag = 1
				End If
			Else
				If RootID>=ALL_FirstRootID Then
					RootID = ALL_FirstRootID-1
					'TopicSortID = ALL_FirstRootID + 1
				
					If RootID<>0 Then
						If WhereFlag = 1 Then
							SQLEndString = SQLEndString & " And ID>" & RootID
						Else
							SQLEndString = SQLEndString & " Where ID>" & RootID
							WhereFlag = 1
						End If
					End If
				Else
					If RootID<>0 Then
						If WhereFlag = 1 Then
							SQLEndString = SQLEndString & " And ID>" & RootID
						Else
							SQLEndString = SQLEndString & " Where ID>" & RootID
							WhereFlag = 1
						End If
					End If
				End If
			End If
		End If

		Dim NoPage
		NoPage = 0

		If Page < 0 or (Page > MaxPage and MaxPage>=(DEF_MaxJumpPageNum-1)) or (Page > (DEF_MaxJumpPageNum-1) and Page<(MaxPage-DEF_MaxJumpPageNum+1)) Then NoPage = 1
		If (RootID > 0 or LastNum>0 or NoPage = 1) and JMPage < 1 Then
			If Upflag="0" Then
				SQLEndString = SQLEndString & " order by ID DESC"
			Else
				SQLEndString = SQLEndString & " order by ID ASC"
			End If
			If LastNum > 0 Then
				Temp = LastNum
			Else
				Temp = DEF_MaxListNum
			End If
		Else
			If JMPage > 0 Then
				If Upflag="0" Then
					SQLEndString = SQLEndString & " order by ID DESC"
					Upflag="0"
					Temp = (JMPage-1) * DEF_MaxListNum + DEF_MaxListNum
				Else
					SQLEndString = SQLEndString & " order by ID ASC"
					Upflag="1"
					Temp = (JMPage-1) * DEF_MaxListNum + DEF_MaxListNum
				End If
			Else
				If Page < DEF_MaxJumpPageNum Then
					SQLEndString = SQLEndString & " order by ID DESC"
					Upflag="0"
					Temp = Page * DEF_MaxListNum + DEF_MaxListNum
				Else
					SQLEndString = SQLEndString & " order by ID ASC"
					Upflag="1"
					Temp = (MaxPage-Page) * DEF_MaxListNum + LastNumBak
				End If
			End If
		End If

		Dim FirstRootID_2,LastRootID_2
		Dim GetData_2

		SQL = "select top " & Temp & " id,ParentID,ChildNum,Layer,Title,FaceIcon,LastTime,Hits,Length,UserName,UserID,RootID,TopicSortID,LastUser,NotReplay,GoodFlag,BoardID,TopicType,PollNum,TitleStyle,LastInfo,ndatetime from LeadBBS_Announce " & SQLEndString
		Set Rs = Con.ExeCute(SQL)
		GBL_DBNum = GBL_DBNum + 1

		If LastNum = "" or isNull(LastNum) then LastNum = 0
		LastNum = cCur(LastNum)
		If (RootID = 0 and Page >= 1 and LastNum = 0 and NoPage = 0) or JMPage > 0 Then
			If Not Rs.Eof Then
				If JMPage > 0 Then
					If Upflag="0" Then
						Rs.Move (JMPage-1)* DEF_MaxListNum
					Else
						If Page < MaxPage Then
							Rs.Move (JMPage-2) * DEF_MaxListNum + DEF_MaxListNum
						End If
					End If
				Else
					If Page < DEF_MaxJumpPageNum Then
						Rs.Move Page * DEF_MaxListNum
					Else
						If Page < MaxPage Then
							Rs.Move (MaxPage-Page-1) * DEF_MaxListNum + LastNumBak
						End If
					End If
				End If
			End If
		End If
		If Not Rs.Eof Then
			HaveRootIDFlag = 1
			GetData_2 = Rs.GetRows(DEF_MaxListNum)
		Else
			HaveRootIDFlag = 0
		End If
		Rs.Close
		Set Rs = Nothing
	
		If HaveRootIDFlag = 1 Then
			Temp2 = Ubound(GetData_2,2)
			FirstRootID_2 = cCur(GetData_2(0,0))
			LastRootID_2 = cCur(GetData_2(0,Temp2))
				
			If FirstRootID_2<LastRootID_2 Then
				SQL = FirstRootID_2
				FirstRootID_2 = LastRootID_2
				LastRootID_2 = SQL
			End If
	
			LastRootID = LastRootID_2
			FirstRootID = FirstRootID_2
		Else
			Temp2 = 0
		End If
	Else
		HaveRootIDFlag = 0
	End If
	
	Dim N

	SQL = "?BoardID=" & GBL_board_ID
	Dim PageSplitString,PageSplitString2
	PageSplitString = "<tr bgcolor=" & DEF_BBS_LightestColor & " height=25 class=TBBG9><td colspan=5><table width=100% border=0 cellspacing=0 cellpadding=0><tr><td><img src=../images/null.gif width=2 height=2><br>&nbsp;"
	If FirstRootID >= ALL_FirstRootID Then
		PageSplitString = PageSplitString & "<font color=888888 class=GrayFont><font face=webdings title=首页>9</font></font>"
		PageSplitString = PageSplitString & " <font color=888888 class=GrayFont><font face=webdings title=上页>7</font></font>"
	Else
		PageSplitString = PageSplitString & "<a href=EBoard.asp" & SQL & "&p=0><font face=webdings title=首页>9</font></a>"
		PageSplitString = PageSplitString & " <a href=EBoard.asp" & SQL & "&RootID=" & FirstRootID & "&Upflag=1&p=" & Page-1 & "><font face=webdings title=上页>7</font></a>"
	End If
	
	Dim DN
	DN = DEF_DisplayJumpPageNum
	Dim For1,For2,StepValue,DotFlag
	DotFlag = 0
	PageSplitString = PageSplitString & " "

	If MaxPage > 0 Then
		For1 = Page - DN
		For2 = Page + DN
		If For1 < 0 Then
			For1 = 0
		End If
		If For2 >= MaxPage Then For2 = MaxPage
		If For2 > MaxPage Then For2 = MaxPage
		If For2 - For1 < DEF_MaxJumpPageNum and For1 > 1 and For2 > For1 Then For1 = For1 - (DEF_MaxJumpPageNum - ((For2 - For1) + 1))
		
		If For1 < 0 Then
			For1 = 0
		ElseIf For1 > 0 Then
			PageSplitString = PageSplitString & " ..."
		End If

		If For2 - For1 < DEF_MaxJumpPageNum and For2 < MaxPage and For2 > For1 Then For2 = For2 + (DEF_MaxJumpPageNum - ((For2 - For1) + 1))
		If For2 >= MaxPage Then For2 = MaxPage

		For N = For1 to For2
			If N <> For1 Then PageSplitString = PageSplitString & " "
			If N = Page Then
				PageSplitString = PageSplitString & "<font color=Red class=RedFont>" & N + 1 & "</font>"
			Else
				If (N-Page) > 0 Then
					PageSplitString = PageSplitString & "<a href=EBoard.asp" & SQL & "&r=" & LastRootID & "&Upflag=0&p=" & page & "&q=" & N-Page & ">" & N + 1 & "</a>"
				Else
					PageSplitString = PageSplitString & "<a href=EBoard.asp" & SQL & "&r=" & FirstRootID & "&Upflag=1&p=" & page & "&q=" & Page-N & ">" & N + 1 & "</a>"
				End If
			End If
			DotFlag = 2
		Next
		If For2 < MaxPage Then
			PageSplitString = PageSplitString & "..."
			DotFlag = 1
		End If
	Else
		PageSplitString = PageSplitString & " <font color=888888 class=GrayFont>1</font> "
	End If
	
	PageSplitString = PageSplitString & " "

	If LastRootID <= ALL_LastRootID Then
		PageSplitString = PageSplitString & " <font color=888888 class=GrayFont><font face=webdings title=下页>8</font></font>"
		PageSplitString = PageSplitString & " <font color=888888 class=GrayFont><font face=webdings title=尾页>:</font></font>"
	Else
		PageSplitString = PageSplitString & " <a href=EBoard.asp" & SQL & "&RootID=" & LastRootID & "&p=" & Page+1 & "><font face=webdings title=下页>8</font></a>"
		PageSplitString = PageSplitString & " <a href=EBoard.asp" & SQL & "&Upflag=1&Num=1&p=" & MaxPage & "><font face=webdings title=尾页>:</font></a>"
	End If

	Rs = Temp1
	Rs = Temp2+Rs
	If HaveRootIDFlag = 1 Then Rs = Rs+1

	if MaxPage < 1 Then MaxPage = 0
	'if MaxPage > 0 Then MaxPage = MaxPage + 1
	If ALL_Count < 0 Then ALL_Count = 0
	PageSplitString = PageSplitString & " 共<b>" & ALL_Count &"</b>帖 第<b>" & Page+1 & "</b>/<b>" & MaxPage+1 & "</b>页 每页<b>" & DEF_MaxListNum & "</b>条<td align=right><img src=../images/null.gif width=2 height=2><br>"
	PageSplitString2 = "</td></tr></table></td></tr>"
	For1 = 0
	For2 = 0
	If Rs < DEF_MaxListNum and GBL_ShowBottomSure = 0 Then GBL_SiteBottomString = ""
	If GBL_TableHeadString <> "" Then%><table width=<%=DEF_BBS_ScreenWidth%> border=0 cellspacing=0 cellpadding=0 align=center><tr><td><%=GBL_TableHeadString%></td></tr></table><%End If%>
	<table width="<%=DEF_BBS_ScreenWidth%>" border="0" cellspacing="1" cellpadding="3" bgcolor="<%=DEF_BBS_DarkColor%>" class=TBone align="center">
	<%'Response.Write PageSplitString
	'Response.Write PageSplitString2%>
	<tr height=20 bgcolor=<%=DEF_BBS_LightDarkColor%> align=center class=TBHead2>
		<td width=20 align=center class=TBHead2><img src=<%=DEF_BBS_HomeUrl%>images/null.gif width=2 height=2><br><b><font color=ffffff class=HeadFont>ID</font></b></td>
		<td align=left class=TBHead2><img src=<%=DEF_BBS_HomeUrl%>images/null.gif width=300 height=2><br>&nbsp;<b><font color=ffffff class=HeadFont>主题</font></b></td>
		<td width=84 class=TBHead2><img src=<%=DEF_BBS_HomeUrl%>images/null.gif width=2 height=2><br><b><font color=ffffff class=HeadFont>作者</font></b></td>
		<td width=50 align=center class=TBHead2><img src=<%=DEF_BBS_HomeUrl%>images/null.gif width=2 height=2><br><b><font color=ffffff title="回复/点击" class=HeadFont>人气</font></b></td>
		<td width=210 align=left class=TBHead2><img src=<%=DEF_BBS_HomeUrl%>images/null.gif width=5 height=2><br><img src=<%=DEF_BBS_HomeUrl%>images/null.gif width=3 height=2><b><font color=ffffff class=HeadFont>　　最后更新　　| 回复人</font></b></td>
	</tr><%
	If Upflag="0" Then
		If HaveRootIDFlag = 1 Then
			If Upflag="0" Then
				For1 = 0
				For2 = Temp2
				StepValue = 1
			Else
				For1 = Temp2
				For2 = 0
				StepValue = -1
			End If
			DisplayAnnounceData For1,For2,StepValue,GetData_2,0
		End If
	Else

		If HaveRootIDFlag = 1 Then
			If Upflag="0" Then
				For1 = 0
				For2 = Temp2
				StepValue = 1
			Else
				For1 = Temp2
				For2 = 0
				StepValue = -1
			End If
			DisplayAnnounceData For1,For2,StepValue,GetData_2,0
		End If
	End If
	Response.Write PageSplitString
	%>
	<!-- #include file=../../inc/IncHtm/BoardJump.asp -->
	<%
	Response.Write PageSplitString2
	Response.Write "</table>"
	If GBL_TableBottomString <> "" Then%><table width=<%=DEF_BBS_ScreenWidth%> border=0 cellspacing=0 cellpadding=0 align=center><tr><td><%=GBL_TableBottomString%></td></tr></table><%End If

End Function

Function DisplayAnnounceData(For1,For2,StepValue,GetData,AllFlag)

	Dim N,Temp,Temp1
	For N = For1 to For2 Step StepValue
		Response.Write "<tr align=center height=25 bgcolor=" & DEF_BBS_LightestColor & " class=TBBG9><td bgcolor=" & DEF_BBS_LightColor & " class=TBBG1>"

		If GetData(17,n) = 80 Then
			If cCur(GetData(18,N)) >= 20 Then
				Temp = "vthot"
			Else
				Temp = "vt"
			End If
		Else
			If GetData(14,n) = 1 Then
				Temp = "lock"
			Else
				If cCur(GetData(2,N)) >= 20 Then
					Temp = "hot"
				Else
					Temp = "tpc"
				End If
			End If
		End If
		Response.Write "<img src=../images/" & GBL_DefineImage & Temp & ".gif align=absbottom width=18 height=18 title=""编号" & GetData(0,N) & """>"
		Response.Write "</td><td align=left>"

		Rem 不显示Layer值
		'If GetData(3,N)>DEF_BBS_MaxLayer Then GetData(3,N)=10
		'Response.Write Replace(string((GetData(3,N)-1),"-"),"-","<ul>")
		Response.Write "<img src=../images/" & GBL_DefineImage & "bf/face" & GetData(5,N) & ".gif align=absbottom width=20 height=20>"

		GetData(8,N) = cCur(GetData(8,N))
		If GetData(8,N) > 1024 Then
			GetData(8,N) = cLng(GetData(8,N)/1024) & " KB"
		Else
			GetData(8,N) = GetData(8,N) & " 字节"
		End If

		If cCur(GetData(1,n)) = 0 Then
			Response.Write " <a href=../Announce/Announce.asp?BoardID=" & GetData(16,N) & "&ID=" & GetData(0,N) & LMT_UrlEndString & " title=""" & GetData(8,N) & """"
		Else
			Response.Write " <a href=../Announce/Announce2.asp?BoardID=" & GetData(16,N) & "&ID=" & GetData(0,N) & LMT_UrlEndString & " title=""" & GetData(8,N) & """"
		End If
		If AllFlag = 1 Then
			Response.Write " target=_blank>"
		Else
			Response.Write ">"
		End If

		GetData(2,N) = cCur(GetData(2,N))
		Temp1 = Fix((GetData(2,N)+1)/DEF_TopicContentMaxListNum)
		If ((GetData(2,N)+1) mod DEF_TopicContentMaxListNum) > 0 Then Temp1 = Temp1 + 1
		If GetData(2,N)>=DEF_TopicContentMaxListNum Then
			Temp = DEF_BBS_DisplayTopicLength - (Len(Temp1) + 3)
		Else
			Temp = DEF_BBS_DisplayTopicLength
		End If
		
		'If GetData(15,n) = True or GetData(15,n) = 1 Then Temp = Temp - 3

		If GetData(19,n) <> 1 and strLength(GetData(4,N))>Temp Then GetData(4,N) = LeftTrue(GetData(4,N),Temp-3) & "..."
		If GetData(19,n) = 0 Then
			Response.Write htmlencode(GetData(4,n))
		Else
			Response.Write DisplayAnnounceTitle(GetData(4,n),GetData(19,n))
		End If
		Response.Write "</a>"

		If GetData(2,N)>=DEF_TopicContentMaxListNum Then
			Response.Write " [<a href=../Announce/Announce.asp?BoardID=" & GetData(16,N) & "&ID=" & GetData(0,N) & "&AUpflag=1&ANum=1" &  LMT_UrlEndString & ">" & Temp1 & "</b></a>]"
		End If

		'If GetData(15,n) = 1 or GetData(15,n) = True Then
		'	Response.Write "<img src=../images/" & GBL_DefineImage & "jh1.GIF border=0 title=精华帖子 align=absbottom width=16 height=16>"
		'End If

		GetData(10,N) = cCur(GetData(10,N))
		If GetData(10,N) > 0 then
			Response.Write "</td><td bgcolor=" & DEF_BBS_LightColor & " class=TBBG1><a href=../User/LookUserInfo.asp?ID=" & GetData(10,N) & ">" & htmlencode(GetData(9,N)) & "</a></td><td>"
		Else
			Response.Write "</td><td>" & htmlencode(GetData(9,N)) & "</td><td>"
		End If

		If isNull(GetData(18,N)) Then GetData(18,N) = 0
		If GetData(17,n) = 80 Then
			Response.Write "共" & cCur(GetData(18,N)) & "票"
		Else
			Response.Write GetData(2,N) & "/" & GetData(7,N)
		End If
		Response.Write "</td><td width=210 align=left bgcolor=" & DEF_BBS_LightColor & " class=TBBG1>&nbsp;"
		Temp = RestoreTime(GetData(6,N))
		If DateDiff("d",Temp,DEF_Now)<1 Then Response.Write "<font color=990000 class=RedFont>"
		If GetData(13,n) = "" or isNull(GetData(13,n)) Then
			Response.Write Left(Temp,16) & " | --------</td></tr>"
		Else
			If GetData(13,n) <> "游客" Then
				Response.Write Left(Temp,16) & " | <a href=" & DEF_BBS_HomeUrl & "User/LookUserInfo.asp?name=" & GetData(13,N) & ">" & htmlencode(GetData(13,n)) & "</a></td></tr>"
			Else
				Response.Write Left(Temp,16) & " | " & htmlencode(GetData(13,n)) & "</td></tr>"
			End If
		End if
	Next

End Function
%>