<% '################################################################################# '## Copyright (C) 2000 Michael Anderson '## '## This program is free software; you can redistribute it and/or '## modify it under the terms of the GNU General Public License '## as published by the Free Software Foundation; either version 2 '## of the License, or any later version. '## '## This program is distributed in the hope that it will be useful, '## but WITHOUT ANY WARRANTY; without even the implied warranty of '## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the '## GNU General Public License for more details. '## '## You should have received a copy of the GNU General Public License '## along with this program; if not, write to the Free Software '## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. '## '## Correspondence and Questions can be sent to: '## reinhold@bigfoot.com '## '## or '## '## Snitz Communications '## C/O: Michael Anderson '## PO Box 200 '## Harpswell, ME 04079 '################################################################################# %> <% mypage = request("whichpage") if mypage = "" then mypage = 1 end if mypagesize = request("pagesize") if mypagesize = "" then mypagesize = 15 end if mySQL = request("strSql") if mySQL = "" then mySQL = SQLtemp end if '## Forum_SQL - Get all active topics from last visit strSql = "SELECT " & strMemberTablePrefix & "MEMBERS.MEMBER_ID, " & strMemberTablePrefix & "MEMBERS.M_STATUS, " & strMemberTablePrefix & "MEMBERS.M_NAME, " & strMemberTablePrefix & "MEMBERS.M_LEVEL, " & strMemberTablePrefix & "MEMBERS.M_EMAIL, " & strMemberTablePrefix & "MEMBERS.M_COUNTRY, " & strMemberTablePrefix & "MEMBERS.M_HOMEPAGE, " & strMemberTablePrefix & "MEMBERS.M_ICQ, " & strMemberTablePrefix & "MEMBERS.M_YAHOO, " & strMemberTablePrefix & "MEMBERS.M_AIM, " & strMemberTablePrefix & "MEMBERS.M_TITLE, " & strMemberTablePrefix & "MEMBERS.M_POSTS, " & strMemberTablePrefix & "MEMBERS.M_LASTPOSTDATE, " & strMemberTablePrefix & "MEMBERS.M_LASTHEREDATE, " & strMemberTablePrefix & "MEMBERS.M_DATE " strSql = strSql & " FROM " & strMemberTablePrefix & "MEMBERS " if mlev = 4 then strSql = strSql & " WHERE " & strMemberTablePrefix & "MEMBERS.M_NAME <> 'n/a' " else strSql = strSql & " WHERE " & strMemberTablePrefix & "MEMBERS.M_STATUS = " & 1 end if select case Request.QueryString("method") case "nameasc" strSql = strSql & " ORDER BY " & strMemberTablePrefix & "MEMBERS.M_NAME ASC;" case "namedesc" strSql = strSql & " ORDER BY " & strMemberTablePrefix & "MEMBERS.M_NAME DESC;" case "levelasc" strSql = strSql & " ORDER BY " & strMemberTablePrefix & "MEMBERS.M_LEVEL ASC, " & strMemberTablePrefix & "MEMBERS.M_NAME ASC;" case "leveldesc" strSql = strSql & " ORDER BY " & strMemberTablePrefix & "MEMBERS.M_LEVEL DESC, " & strMemberTablePrefix & "MEMBERS.M_NAME ASC;" case "lastpostdateasc" strSql = strSql & " ORDER BY " & strMemberTablePrefix & "MEMBERS.M_LASTPOSTDATE ASC, " & strMemberTablePrefix & "MEMBERS.M_NAME ASC;" case "lastpostdatedesc" strSql = strSql & " ORDER BY " & strMemberTablePrefix & "MEMBERS.M_LASTPOSTDATE DESC, " & strMemberTablePrefix & "MEMBERS.M_NAME ASC;" case "lastheredateasc" strSql = strSql & " ORDER BY " & strMemberTablePrefix & "MEMBERS.M_LASTHEREDATE ASC, " & strMemberTablePrefix & "MEMBERS.M_NAME ASC;" case "lastheredatedesc" strSql = strSql & " ORDER BY " & strMemberTablePrefix & "MEMBERS.M_LASTHEREDATE DESC, " & strMemberTablePrefix & "MEMBERS.M_NAME ASC;" case "dateasc" strSql = strSql & " ORDER BY " & strMemberTablePrefix & "MEMBERS.M_DATE ASC, " & strMemberTablePrefix & "MEMBERS.M_NAME ASC;" case "datedesc" strSql = strSql & " ORDER BY " & strMemberTablePrefix & "MEMBERS.M_DATE DESC, " & strMemberTablePrefix & "MEMBERS.M_NAME ASC;" case "countryasc" strSql = strSql & " ORDER BY " & strMemberTablePrefix & "MEMBERS.M_COUNTRY ASC, " & strMemberTablePrefix & "MEMBERS.M_NAME ASC;" case "countrydesc" strSql = strSql & " ORDER BY " & strMemberTablePrefix & "MEMBERS.M_COUNTRY DESC, " & strMemberTablePrefix & "MEMBERS.M_NAME ASC;" case "postsasc" strSql = strSql & " ORDER BY " & strMemberTablePrefix & "MEMBERS.M_POSTS ASC, " & strMemberTablePrefix & "MEMBERS.M_NAME ASC;" case else strSql = strSql & " ORDER BY " & strMemberTablePrefix & "MEMBERS.M_POSTS DESC, " & strMemberTablePrefix & "MEMBERS.M_NAME ASC;" end select Set rs = Server.CreateObject("ADODB.RecordSet") rs.open strSql, my_conn, 3 if not (rs.EOF or rs.BOF) then '## No categories found in DB rs.movefirst rs.pagesize = mypagesize maxpages = cint(rs.pagecount) end if %>
 All Forums
 Member Information
<% if maxpages > 1 then %>
Pages:    <% Call Paging() %>
<% else %>   <% end if %>
<% if mlev = 4 or mlev = 3 then %> <% end if %> <% if mlev = 4 then %> <% end if %> <% If rs.EOF or rs.BOF then '## No Members Found in DB %> <% Else %> <% currMember = 0 %> <% i = 0 rs.cacheSize = 15 rs.moveFirst rs.pageSize = myPageSize maxPages = cint(rs.pageCount) maxRecs = cint(rs.pageSize) rs.absolutePage = myPage howManyRecs = 0 rec = 1 do until rs.Eof or rec = 16 if i = 1 then CColor = strAltForumCellColor else CColor = strForumCellColor end if '## Set Member Level which is displayed to show in the forum Member_Level = "" call doMember_Level() Star_Level = "" call doStar_Level() %> <% if IsNull(rs("M_LASTPOSTDATE"))then%> <% else %> <% end if %> <% if mlev = 4 or mlev = 3 then %> <% end if %> <% if mlev = 4 then %> <% end if %> <% currMember = rs("MEMBER_ID") rs.MoveNext i = i + 1 if i = 2 then i = 0 rec = rec + 1 loop end if %>
  ">Member Name ">Title ">Posts ">Last Post ">Member Since ">Country">Last Visit 
">No Members Found
')"><% if rs("M_STATUS") = 0 then %>View Member's Profile<% else %>View Member's Profile<% end if %> <% if strICQ = "1" and rs("M_ICQ") <> " " then %> &M_NAME=<% =ChkString(rs("M_NAME"),"display") %>')">&img=5" height=15 width=15 alt="Send <% =ChkString(rs("M_NAME"),"display") %> an ICQ Message" border="0" align="absmiddle" hspace="0"> <% end if %> <% if strYAHOO = "1" and rs("M_YAHOO") <> " " then %> &.src=pg')">Send <% =ChkString(rs( a Yahoo! Message" border="0" align="absmiddle" hspace="0"> <% end if %> <% if strAIM = "1" and rs("M_AIM") <> " " then %> &M_NAME=<% =ChkString(rs("M_NAME"),"display") %>')">Send <% =ChkString(rs( an instant message" border="0" align="absmiddle" hspace="0"> <% end if %> ')"><% =ChkString(rs("M_NAME"),"display") %> <% =ChkString(Member_Level,"display") %> <% if IsNull(rs("M_POSTS")) then %> - <% else %> <% =rs("M_POSTS") %> <% if strShowRank = 2 or strShowRank = 3 then %>
<% =Star_Level %> <% end if %> <% end if %>
-<% =ChkDate(rs("M_LASTPOSTDATE")) %><% =ChkDate(rs("M_DATE")) %> <% =rs("M_COUNTRY") %> <% =ChkDate(rs("M_LASTHEREDATE")) %> <% if rs("MEMBER_ID") <> 1 then %> <% if rs("M_STATUS") <> 0 then %> ')">Lock Member <% else %> ')">Un-Lock Member <% end if %> <% end if %> &name=<% =ChkString(rs("M_NAME"),"urlpath") %>')">Edit Member <% if rs("MEMBER_ID") = 1 then %> <% '## Do Nothing %> <% else %> ')">Delete Member <% end if %>
<% if maxpages > 1 then %>
Members are <% =maxpages %> Pages Long:    <% Call Paging() %>
<% else %>   <% end if %>
<% sub Paging() if maxpages > 1 then if Request.QueryString("whichpage") = "" then sPageNumber = 1 else sPageNumber = Request.QueryString("whichpage") end if if Request.QueryString("method") = "" then sMethod = "postsdesc" else sMethod = Request.QueryString("method") end if sScriptName = Request.ServerVariables("script_name") Response.Write("") for counter = 1 to maxpages if counter <> cint(sPageNumber) then sNum = "" Response.Write sNum else Response.Write("") end if if counter mod 15 = 0 then Response.Write("") end if next Response.Write("
" & " " & widenum(counter) & "" & counter & "" & " " & widenum(counter) & "" & counter & "
") end if end sub %>