<% '************************************************************** ' Software name: PowerEasy SiteWeaver ' Web: http://www.powereasy.net ' Copyright (C) 2005-2009 佛山市动易网络科技有限公司 版权所有 '************************************************************** PageTitle = "作者列表" strFileName = "AuthorList.asp" Dim strtmp, HotNum Dim tempChannelID Dim iUsername, i, rsAuthor, sqlAuthor ChannelID = PE_Clng(Trim(Request("ChannelID"))) If ChannelID > 0 Then strFileName = "AuthorList.asp?ChannelID=" & ChannelID Call GetChannel(ChannelID) Else ChannelName = "全部频道" End If iUsername = Trim(Request("Username")) If iUsername <> "" Then iUsername = ReplaceBadChar(iUsername) strFileName = strFileName & "&Username=" & iUsername End If MaxPerPage = 20 strNavPath = strNavPath & strNavLink & " " & PageTitle HotNum = 100 strHTML = GetTemplate(0, 11, 0) Call ReplaceCommonLabel strHTML = Replace(strHTML, "{$PageTitle}", SiteTitle & " >> " & PageTitle) strHTML = Replace(strHTML, "{$ShowPath}", strNavPath) strHTML = Replace(strHTML, "{$MenuJS}", GetMenuJS("", False)) strHTML = Replace(strHTML, "{$Skin_CSS}", GetSkin_CSS(0)) strHTML = Replace(strHTML, "{$GetAuthorList}", ShowAuthorList()) Response.Write strHTML Call CloseConn Function ShowAuthorList() strtmp = "" strtmp = strtmp & " " strtmp = strtmp & "" rsAuthor.MoveNext i = i + 1 If i >= MaxPerPage Then Exit Do Loop strtmp = strtmp & "
" & ChannelName & "作者列表" & "
" sqlAuthor = "select * from PE_Author Where Passed=" & PE_True If ChannelID > 0 Then sqlAuthor = sqlAuthor & " and (ChannelID=" & ChannelID &" Or ChannelID = 0)" If iUsername <> "" Then sqlAuthor = sqlAuthor & " and UserName='" & iUsername & "'" If Action = "ListElite" Then sqlAuthor = sqlAuthor & " and isElite=" & PE_True If Action = "ListHot" Then sqlAuthor = sqlAuthor & " and Hits>" & HotNum sqlAuthor = sqlAuthor & " order by onTop " & PE_OrderType & ",LastUseTime Desc" Set rsAuthor = Server.CreateObject("ADODB.Recordset") rsAuthor.Open sqlAuthor, Conn, 1, 1 If rsAuthor.BOF And rsAuthor.EOF Then totalPut = 0 strtmp = strtmp & "
" & XmlText("ShowSource", "ShowAuthorList/t1", "姓名") & "" & XmlText("ShowSource", "ShowAuthorList/t2", "性别") & "" & XmlText("ShowSource", "ShowAuthorList/t3", "所属频道") & "" & XmlText("ShowSource", "ShowAuthorList/t4", "作者简介") & "
" & XmlText("ShowSource", "ShowAuthorList/NoFoundAuthor", "本频道尚未添加作者") & "
" Else totalPut = rsAuthor.RecordCount If CurrentPage > 1 Then If (CurrentPage - 1) * MaxPerPage < totalPut Then rsAuthor.Move (CurrentPage - 1) * MaxPerPage Else CurrentPage = 1 End If End If i = 0 Do While Not rsAuthor.EOF If PE_CLng(rsAuthor("ChannelID")) = 0 Then tempChannelID = ChannelID Else tempChannelID = PE_CLng(rsAuthor("ChannelID")) End If If tempChannelID > 0 Then strtmp = strtmp & "
" & rsAuthor("AuthorName") & "" Else strtmp = strtmp & "
" & rsAuthor("AuthorName") & "" End If If rsAuthor("Sex") = 1 Then strtmp = strtmp & strMan Else strtmp = strtmp & strGirl End If If rsAuthor("ChannelID") <> PrevChannelID Then Call GetChannel(rsAuthor("ChannelID")) PrevChannelID = rsAuthor("ChannelID") End If strtmp = strtmp & " " & ChannelName & " " & Left(nohtml(rsAuthor("Intro")), 200) & "
" & ShowPage(strFileName, totalPut, MaxPerPage, CurrentPage, True, True, XmlText("ShowSource", "ShowAuthorList/PageChar", "个作者"), False) & "" End If rsAuthor.Close Set rsAuthor = Nothing ShowAuthorList = strtmp End Function %>