T O P I C R E V I E W |
MaGraham |
Posted - 15 December 2013 : 07:19:29 On active.asp there's the option on the top-left to "Mark as Read" to mark all topics as read. And, on the default.asp there's the option to "Collapse This Category" that, obviously, hides everything in that particular category.
Perhaps using the two of those above, could someone come up with a means to "Hide This Forum" for each of the forums listed on active.asp?
Can you imagine going to active.asp and there being 50 or more "Blogs" listed on the Blog Forum and at least 45 or more "Do it Yourself Crafts" posts listed on the Crafts Forum because of the holidays. . .and that's just two forums. Then, obviously, there are numerous other forums having topics for them as well.
And if you weren't interested in many of those, wouldn't you want to just click to hide 'em? And if you thought you might change your mind, wouldn't you like to just hide 'em until later. Or, you'd continuously have to scroll past them.
Could this be some sort of addon for active.asp?
|
12 L A T E S T R E P L I E S (Newest First) |
HuwR |
Posted - 07 June 2014 : 03:18:47 no worries, I promise I haven't forgotten either , currently studying for a Microsoft exam next week, so brain is on total meltdown at the moment |
MaGraham |
Posted - 07 June 2014 : 01:26:49 Sorry! I meant to come back earlier and say that I do understand, HuwR.
May God bless your faithfulness to work so hard on the .net project.
|
HuwR |
Posted - 21 May 2014 : 07:06:31 Unfortunately not as yet, I have been a bit tied up working on the .net project. |
MaGraham |
Posted - 20 May 2014 : 23:56:14 I know everyone seems really busy right now but I was wanting to do a tutorial for my "Active Topics" so I thought I'd check in to see if HuwR has had time to look at this again.
I really can't remember if I've made changes to my active.asp since I last posted a copy of it so I thought it best to post it again.
I am so excited to see Snitz busy again!
<%
'###############################################################################
'##
'## Snitz Forums 2000 v3.4.07
'##
'###############################################################################
'##
'## Copyright © 2000-09 Michael Anderson, Pierre Gorissen,
'## Huw Reddick and Richard Kinser
'##
'## This program is free. You can redistribute and/or modify it under the
'## terms of the GNU General Public License as published by the Free Software
'## Foundation; either version 2 or (at your option) any later version.
'##
'## All copyright notices regarding Snitz Forums 2000 must remain intact in
'## the scripts and in the HTML output. The "powered by" text/logo with a
'## link back to http://forum.snitz.com in the footer of the pages MUST
'## remain visible when the pages are viewed on the internet or intranet.
'##
'## This program is distributed in the hope that it will be useful but
'## WITHOUT ANY WARRANTY; without even an 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:
'##
'## Free Software Foundation, Inc.
'## 59 Temple Place, Suite 330
'## Boston, MA 02111-1307
'##
'## Support can be obtained from our support forums at:
'##
'## http://forum.snitz.com
'##
'## Correspondence and marketing questions can be sent to:
'##
'## manderson@snitz.com
'##
'###############################################################################
%>
<!--#INCLUDE FILE="config.asp"-->
<!--#INCLUDE FILE="inc_sha256.asp" -->
<!--#INCLUDE FILE="inc_header.asp" -->
<!--#INCLUDE FILE="inc_func_secure.asp" -->
<!--#INCLUDE FILE="inc_func_chknew.asp" -->
<!--#INCLUDE FILE="inc_subscription.asp" -->
<!--#INCLUDE FILE="inc_moderation.asp" -->
<!--#INCLUDE FILE="inc_birthdays.asp" -->
<%
nRefreshTime = Request.Cookies(strCookieURL & "Reload")
If Request.Form("cookie") = "1" Then
If strSetCookieToForum = 1 Then
Response.Cookies(strCookieURL & "Reload").Path = strCookieURL
End If
Response.Cookies(strCookieURL & "Reload") = Request.Form("RefreshTime")
Response.Cookies(strCookieURL & "Reload").Expires = strForumTimeAdjust + 365
nRefreshTime = Request.Form("RefreshTime")
End If
If nRefreshTime = "" Then
nRefreshTime = 10
End If
ActiveSince = Request.Cookies(strCookieURL & "ActiveSince")
If Request.Form("cookie") = "2" Then
ActiveSince = Request.Form("ShowSinceDateTime")
If strSetCookieToForum = 1 Then
Response.Cookies(strCookieURL & "ActiveSince").Path = strCookieURL
End If
Response.Cookies(strCookieURL & "ActiveSince") = ActiveSince
End If
Dim ModerateAllowed
Dim HasHigherSub
Dim HeldFound, UnApprovedFound, UnModeratedPosts, UnModeratedFPosts
Dim canView
HasHigherSub = false
Select Case ActiveSince
Case "LastVisit"
lastDate = ""
Case "LastFifteen"
lastDate = DateToStr(DateAdd("n",-15,strForumTimeAdjust))
Case "LastThirty"
lastDate = DateToStr(DateAdd("n",-30,strForumTimeAdjust))
Case "LastFortyFive"
lastDate = DateToStr(DateAdd("n",-45,strForumTimeAdjust))
Case "LastHour"
lastDate = DateToStr(DateAdd("h",-1,strForumTimeAdjust))
Case "Last2Hours"
lastDate = DateToStr(DateAdd("h",-2,strForumTimeAdjust))
Case "Last6Hours"
lastDate = DateToStr(DateAdd("h",-6,strForumTimeAdjust))
Case "Last12Hours"
lastDate = DateToStr(DateAdd("h",-12,strForumTimeAdjust))
Case "LastDay"
lastDate = DateToStr(DateAdd("d",-1,strForumTimeAdjust))
Case "Last2Days"
lastDate = DateToStr(DateAdd("d",-2,strForumTimeAdjust))
Case "LastWeek"
lastDate = DateToStr(DateAdd("ww",-1,strForumTimeAdjust))
Case "Last2Weeks"
lastDate = DateToStr(DateAdd("ww",-2,strForumTimeAdjust))
Case "LastMonth"
lastDate = DateToStr(DateAdd("m",-1,strForumTimeAdjust))
Case "Last2Months"
lastDate = DateToStr(DateAdd("m",-2,strForumTimeAdjust))
Case Else
lastDate = ""
End Select
Response.Write " <script language=""JavaScript"" type=""text/javascript"">" & vbNewLine & _
" <!--" & vbNewLine & _
" function autoReload() { document.ReloadFrm.submit() }" & vbNewLine & _
" function SetLastDate() { document.LastDateFrm.submit() }" & vbNewLine & _
" function jumpTo(s) { if (s.selectedIndex != 0) location.href = s.options[s.selectedIndex].value;return 1;}" & vbNewLine & _
" //defaultStatus = ""You last loaded this page on " & chkDate(DateToStr(strForumTimeAdjust)," ",true) & " (Forum Time)""" & vbNewLine & _
" // -->" & vbNewLine & _
" </script>" & vbNewLine
If IsEmpty(Session(strCookieURL & "last_here_date")) Then
Session(strCookieURL & "last_here_date") = ReadLastHereDate(strDBNTUserName)
End If
If lastDate = "" Then
lastDate = DateToStr(DateAdd("d",-1,strForumTimeAdjust))
End If
If Request.Form("AllRead") = "Y" Then
lastDate = ChkString(Request.Form("BuildTime"),"SQLString")
'## The redundant line below is necessary, don't delete it.
Session(strCookieURL & "last_here_date") = lastDate
Session(strCookieURL & "last_here_date") = lastDate
UpdateLastHereDate lastDate,strDBNTUserName
ActiveSince = ""
End If
If strModeration = "1" and mLev > 2 Then
UnModeratedPosts = CheckForUnmoderatedPosts("BOARD", 0, 0, 0)
End If
Dim strSubString, strSubArray, strBoardSubs, strCatSubs, strForumSubs, strTopicSubs
If MySubCount > 0 Then
strSubString = PullSubscriptions(0,0,0)
strSubArray = Split(strSubString,";")
If uBound(strSubArray) < 0 Then
strBoardSubs = ""
strCatSubs = ""
strForumSubs = ""
strTopicSubs = ""
Else
strBoardSubs = strSubArray(0)
strCatSubs = strSubArray(1)
strForumSubs = strSubArray(2)
strTopicSubs = strSubArray(3)
End If
End If
If mlev = 3 Then
strSql = "SELECT FORUM_ID FROM " & strTablePrefix & "MODERATOR " & _
" WHERE MEMBER_ID = " & MemberID
Set rsMod = Server.CreateObject("ADODB.Recordset")
rsMod.Open strSql, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText
If rsMod.EOF Then
recModCount = ""
Else
allModData = rsMod.GetRows(adGetRowsRest)
recModCount = UBound(allModData,2)
End If
RsMod.Close
Set RsMod = Nothing
If recModCount <> "" Then
For x = 0 to recModCount
If x = 0 Then
ModOfForums = allModData(0,x)
Else
ModOfForums = ModOfForums & "," & allModData(0,x)
End If
Next
Else
ModOfForums = ""
End If
Else
ModOfForums = ""
End If
If strPrivateForums = "1" and mLev < 4 Then
allAllowedForums = ""
allowSql = "SELECT FORUM_ID, F_SUBJECT, F_PRIVATEFORUMS, F_PASSWORD_NEW"
allowSql = allowSql & " FROM " & strTablePrefix & "FORUM"
allowSql = allowSql & " WHERE F_TYPE = 0"
allowSql = allowSql & " ORDER BY FORUM_ID"
Set rsAllowed = Server.CreateObject("ADODB.Recordset")
rsAllowed.Open allowSql, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText
If rsAllowed.EOF Then
recAllowedCount = ""
Else
allAllowedData = rsAllowed.GetRows(adGetRowsRest)
recAllowedCount = UBound(allAllowedData,2)
End If
rsAllowed.Close
Set rsAllowed = Nothing
If recAllowedCount <> "" Then
fFORUM_ID = 0
fF_SUBJECT = 1
fF_PRIVATEFORUMS = 2
fF_PASSWORD_NEW = 3
For RowCount = 0 to recAllowedCount
Forum_ID = allAllowedData(fFORUM_ID,RowCount)
Forum_Subject = allAllowedData(fF_SUBJECT,RowCount)
Forum_PrivateForums = allAllowedData(fF_PRIVATEFORUMS,RowCount)
Forum_FPasswordNew = allAllowedData(fF_PASSWORD_NEW,RowCount)
If mLev > 3 Then
ModerateAllowed = "Y"
ElseIf mLev = 3 and ModOfForums <> "" Then
If (strAuthType = "nt") Then
If (chkForumModerator(Forum_ID, Session(strCookieURL & "username")) = "1") Then ModerateAllowed = "Y" Else ModerateAllowed = "N"
Else
If (instr("," & ModOfForums & "," ,"," & Forum_ID & ",") > 0) Then ModerateAllowed = "Y" Else ModerateAllowed = "N"
End If
Else
ModerateAllowed = "N"
End If
If chkForumAccessNew(Forum_PrivateForums,Forum_FPasswordNew,Forum_Subject,Forum_ID,MemberID) = true Then
If allAllowedForums = "" Then
allAllowedForums = Forum_ID
Else
allAllowedForums = allAllowedForums & "," & Forum_ID
End If
End If
Next
End If
If allAllowedForums = "" Then allAllowedForums = 0
End If
' ## Msg Icon & Poll Below
strSql = "SELECT F.FORUM_ID, " & _
"F.F_SUBJECT, " & _
"F.F_SUBSCRIPTION, " & _
"F.F_STATUS, " & _
"C.CAT_ID, " & _
"C.CAT_NAME, " & _
"C.CAT_SUBSCRIPTION, " & _
"C.CAT_STATUS, " & _
"T.T_STATUS, " & _
"T.T_VIEW_COUNT, " & _
"T.TOPIC_ID, " & _
"T.T_ISPOLL, " &_
"T.T_SUBJECT, " & _
"T.T_AUTHOR, " & _
"T.T_REPLIES, " & _
"T.T_UREPLIES, " & _
"M.M_NAME, " & _
"T.T_LAST_POST_AUTHOR, " & _
"T.T_LAST_POST, " & _
"T.T_LAST_POST_REPLY_ID, " & _
"MEMBERS_1.M_NAME AS LAST_POST_AUTHOR_NAME, " & _
"T.T_MSGICON, " & _
"F.F_PRIVATEFORUMS, " & _
"F.F_PASSWORD_NEW, " & _
"M.M_AVATAR_URL " & _
"FROM " & strMemberTablePrefix & "MEMBERS M, " & _
strTablePrefix & "FORUM F, " & _
strTablePrefix & "TOPICS T, " & _
strTablePrefix & "CATEGORY C, " & _
strMemberTablePrefix & "MEMBERS MEMBERS_1 " & _
"WHERE T.T_LAST_POST_AUTHOR = MEMBERS_1.MEMBER_ID "
' ## Msg Icon & Poll Above
If strPrivateForums = "1" and mLev < 4 Then
strSql = strSql & " AND F.FORUM_ID IN (" & allAllowedForums & ") "
End If
' ## UserGroup Below
strDeniedForums = Session(strCookieURL & "DeniedForums" & MemberID)
If strDeniedForums <> "" and strDeniedForums <> "-1" Then
strSql = strSql & " AND F.FORUM_ID NOT IN(" & Session(strCookieURL & "DeniedForums" & MemberID) & ") "
End If
' ## UserGroup Above
strSql = strSql & "AND F.F_TYPE = 0 " & _
"AND F.FORUM_ID = T.FORUM_ID " & _
"AND C.CAT_ID = T.CAT_ID " & _
"AND M.MEMBER_ID = T.T_AUTHOR " & _
"AND (T.T_LAST_POST > '" & lastDate & "'"
If mlev <> 4 Then
strSql = strSql & " AND ((T.T_AUTHOR <> " & MemberID &_
" AND T.T_STATUS < 2)"
If mlev = 3 and ModOfForums <> "" Then
strSql = strSql & " OR T.FORUM_ID IN (" & ModOfForums & ") "
End If
strSql = strSql & " OR T.T_AUTHOR = " & MemberID & ")"
End If
If Group > 1 and strGroupCategories = "1" Then
strSql = strSql & " AND (C.CAT_ID = 0"
If recGroupCatCount <> "" Then
For iGroupCat = 0 to recGroupCatCount
strSql = strSql & " or C.CAT_ID = " & allGroupCatData(1, iGroupCat)
Next
strSql = strSql & ")"
Else
strSql = strSql & ")"
End If
End If
strSql = strSql & ") "
strSql = strSql & " ORDER BY C.CAT_ORDER, C.CAT_NAME, F.F_ORDER, F.F_SUBJECT, T.T_LAST_POST DESC "
Set rs = Server.CreateObject("ADODB.Recordset")
If strDBType <> "mysql" Then rs.cachesize = 50
rs.Open strSql, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText
If rs.EOF Then
recActiveTopicsCount = ""
Else
allActiveTopics = rs.GetRows(adGetRowsRest)
recActiveTopicsCount = UBound(allActiveTopics,2)
rs.Close
End If
Set rs = Nothing
' ## Events Calendar Below
strSQL = "SELECT T.TOPIC_ID FROM " & strTablePrefix & "TOPICS AS T INNER JOIN " & strTablePrefix & "CAL_EVENTS AS C ON T.TOPIC_ID = C.TOPIC_ID WHERE T.T_LAST_POST > '" & lastDate & "' GROUP BY T.TOPIC_ID"
Set rsCal = Server.CreateObject("ADODB.Recordset")
rsCal.Open StrSql, My_conn
If not rsCal.EOF Then
arrTopicID = rsCal.GetRows
rsCal.Close
Else
blnCalNoEvents = TRUE
End If
Set rsCal = Nothing
' ## Events Calendar Above
Response.Write " <table width=""100%"" border=""0"" cellspacing=""0"" cellpadding=""0"" align=""center"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <form name=""LastDateFrm"" action=""active.asp"" method=""post""><td>" & vbNewLine & _
" <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine & _
" " & getCurrentIcon(strIconFolderOpen,"","") & " <a href=""default.asp"">COMMUNITY HOME</a><br />" & vbNewLine & _
" " & getCurrentIcon(strIconBar,"","") & getCurrentIcon(strIconFolderOpenTopic,"","") & " " & _
"Active Topics Since " & vbNewLine
Response.Write " <select name=""ShowSinceDateTime"" size=""1"" onchange=""SetLastDate();"">" & vbNewLine & _
" <option value=""LastVisit""" & "nbsp;Last Visit on " & ChkDate(Session(strCookieURL & "last_here_date"),"",true) & " </option>" & vbNewLine & _
" <option value=""LastFifteen""" & chkSelect(ActiveSince,"LastFifteen") & "> Last 15 minutes</option>" & vbNewLine & _
" <option value=""LastThirty""" & chkSelect(ActiveSince,"LastThirty") & "> Last 30 minutes</option>" & vbNewLine & _
" <option value=""LastFortyFive""" & chkSelect(ActiveSince,"LastFortyFive") & "> Last 45 minutes</option>" & vbNewLine & _
" <option value=""LastHour""" & chkSelect(ActiveSince,"LastHour") & "> Last Hour</option>" & vbNewLine & _
" <option value=""Last2Hours""" & chkSelect(ActiveSince,"Last2Hours") & "> Last 2 Hours</option>" & vbNewLine & _
" <option value=""Last6Hours""" & chkSelect(ActiveSince,"Last6Hours") & "> Last 6 Hours</option>" & vbNewLine & _
" <option value=""Last12Hours""" & chkSelect(ActiveSince,"Last12Hours") & "> Last 12 Hours</option>" & vbNewLine & _
" <option value=""LastDay""" & chkSelect(ActiveSince,"LastDay")
If ActiveSince = "LastDay" or ActiveSince = "" Then
Response.Write " selected"
End If
Response.Write "> Yesterday</option>" & vbNewLine & _
" <option value=""Last2Days""" & chkSelect(ActiveSince,"Last2Days") & "> Last 2 Days</option>" & vbNewLine & _
" <option value=""LastWeek""" & chkSelect(ActiveSince,"LastWeek") & "> Last Week</option>" & vbNewLine & _
" <option value=""Last2Weeks""" & chkSelect(ActiveSince,"Last2Weeks") & "> Last 2 Weeks</option>" & vbNewLine & _
" <option value=""LastMonth""" & chkSelect(ActiveSince,"LastMonth") & "> Last Month</option>" & vbNewLine & _
" <option value=""Last2Months""" & chkSelect(ActiveSince,"Last2Months") & "> Last 2 Months</option>" & vbNewLine & _
" </select>" & vbNewLine & _
" <input type=""hidden"" name=""Cookie"" value=""2"">" & vbNewLine & _
" </font>" & vbNewLine & _
" </td>" & vbNewLine & _
" </form>" & vbNewLine & _
" <td align=""center""> </td>" & vbNewLine & _
" <form name=""ReloadFrm"" action=""active.asp"" method=""post"">" & vbNewLine & _
" <td align=""right"">" & vbNewLine & _
" <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & _
" <br />" & vbNewLine & _
" <select name=""RefreshTime"" size=""1"" onchange=""autoReload();"">" & vbNewLine & _
" <option value=""0""" & chkSelect(nRefreshTime,0) & ">Don't reload automatically</option>" & vbNewLine & _
" <option value=""1""" & chkSelect(nRefreshTime,1) & ">Reload page every minute</option>" & vbNewLine & _
" <option value=""2""" & chkSelect(nRefreshTime,2) & ">Reload page every 2 minutes</option>" & vbNewLine & _
" <option value=""5""" & chkSelect(nRefreshTime,5) & ">Reload page every 5 minutes</option>" & vbNewLine & _
" <option value=""10""" & chkSelect(nRefreshTime,10) & ">Reload page every 10 minutes</option>" & vbNewLine & _
" <option value=""15""" & chkSelect(nRefreshTime,15) & ">Reload page every 15 minutes</option>" & vbNewLine & _
" </select>" & vbNewLine & _
" <input type=""hidden"" name=""Cookie"" value=""1"">" & vbNewLine & _
" </font>" & vbNewLine & _
" </td>" & vbNewLine & _
" </form>" & vbNewLine & _
" </tr>" & vbNewLine & _
" </table>" & vbNewLine & _
" <font size=""" & strFooterFontSize & """><br /></font>" & vbNewLine & _
" <table border=""0"" width=""100%"" cellspacing=""0"" cellpadding=""0"" align=""center"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td bgcolor=""" & strTableBorderColor & """>" & vbNewLine & _
" <table border=""0"" width=""100%"" cellspacing=""1"" cellpadding=""4"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """ valign=""middle""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>" & vbNewLine
If recActiveTopicsCount <> "" and (mLev > 0) Then
Response.Write " <form name=""MarkRead"" action=""active.asp"" method=""post"" style=""display:inline"">" & vbNewLine & _
" <input type=""hidden"" name=""AllRead"" value=""Y"">" & vbNewLine & _
" <input type=""hidden"" name=""BuildTime"" value=""" & DateToStr(strForumTimeAdjust) & """>" & vbNewLine & _
" <input type=""hidden"" name=""Cookie"" value=""2"">" & vbNewLine & _
" <acronym style=""border:none; text-decoration:none"" title=""Mark all topics as read""><input type=""image"" src=""" & strImageUrl & "icon_topic_all_read.png"" value=""Mark all read"" id=""submit1"" name=""Mark all topics as read"" border=""0""" & dWStatus("Mark all topics as read") & "></acronym></font></td>" & vbNewLine & _
" </form>" & vbNewLine
Else
Response.Write " </font></td>" & vbNewLine
End If
Response.Write " <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """> </font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Topic</font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Author</font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Comments</font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Read</font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Last Poster</font></b></td>" & vbNewLine
If (mlev > 0) or (lcase(strNoCookies) = "1") Then
Response.Write " <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>"
If (mLev > 2) or (lcase(strNoCookies) = "1") Then
If UnModeratedPosts > 0 Then
UnModeratedFPosts = 0
Response.Write "<a href=""moderate.asp"">" & getCurrentIcon(strIconFolderModerate,"View All UnModerated Posts","hspace=""0""") & "</a>"
Else
Response.Write(" ")
End If
Else
Response.Write(" ")
End If
Response.Write "</font></b></td>" & vbNewLine
End If
Response.Write " </tr>" & vbNewLine
If recActiveTopicsCount = "" Then
Response.Write " <tr>" & vbNewLine & _
" <td colspan=""8"" bgcolor=""" & strForumCellColor & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """><b>No Active Topics Found</b></font></td>" & vbNewLine & _
" </tr>" & vbNewLine
Else
currForum = 0
fDisplayCount = 0
canAccess = 0
fFORUM_ID = 0
fF_SUBJECT = 1
fF_SUBSCRIPTION = 2
fF_STATUS = 3
fCAT_ID = 4
fCAT_NAME = 5
fCAT_SUBSCRIPTION = 6
fCAT_STATUS = 7
fT_STATUS = 8
fT_VIEW_COUNT = 9
fTOPIC_ID = 10
' ## Poll Below
fIS_POLL = 11
' ## Poll Above
fT_SUBJECT = 12
fT_AUTHOR = 13
fT_REPLIES = 14
fT_UREPLIES = 15
fM_NAME = 16
fT_LAST_POST_AUTHOR = 17
fT_LAST_POST = 18
fT_LAST_POST_REPLY_ID = 19
fLAST_POST_AUTHOR_NAME = 20
fT_MSGICON = 21
fF_PRIVATEFORUMS = 22
fF_PASSWORD_NEW = 23
fM_AVATAR_URL = 24
For RowCount = 0 to recActiveTopicsCount
'## Store all the recordvalues in variables first.
Forum_ID = allActiveTopics(fFORUM_ID,RowCount)
Forum_Subject = allActiveTopics(fF_SUBJECT,RowCount)
ForumSubscription = allActiveTopics(fF_SUBSCRIPTION,RowCount)
Forum_Status = allActiveTopics(fF_STATUS,RowCount)
Cat_ID = allActiveTopics(fCAT_ID,RowCount)
Cat_Name = allActiveTopics(fCAT_NAME,RowCount)
CatSubscription = allActiveTopics(fCAT_SUBSCRIPTION,RowCount)
Cat_Status = allActiveTopics(fCAT_STATUS,RowCount)
Topic_Status = allActiveTopics(fT_STATUS,RowCount)
Topic_View_Count = allActiveTopics(fT_VIEW_COUNT,RowCount)
Topic_ID = allActiveTopics(fTOPIC_ID,RowCount)
Topic_Subject = allActiveTopics(fT_SUBJECT,RowCount)
Topic_Author = allActiveTopics(fT_AUTHOR,RowCount)
Topic_Replies = allActiveTopics(fT_REPLIES,RowCount)
Topic_UReplies = allActiveTopics(fT_UREPLIES,RowCount)
Member_Name = allActiveTopics(fM_NAME,RowCount)
Topic_Last_Post_Author = allActiveTopics(fT_LAST_POST_AUTHOR,RowCount)
Topic_Last_Post = allActiveTopics(fT_LAST_POST,RowCount)
Topic_Last_Post_Reply_ID = allActiveTopics(fT_LAST_POST_REPLY_ID,RowCount)
Topic_Last_Post_Author_Name = chkString(allActiveTopics(fLAST_POST_AUTHOR_NAME,RowCount),"display")
Topic_MsgIcon = allActiveTopics(fT_MSGICON,RowCount)
Forum_PrivateForums = allActiveTopics(fF_PRIVATEFORUMS,RowCount)
Forum_FPasswordNew = allActiveTopics(fF_PASSWORD_NEW,RowCount)
Member_Avatar = allActiveTopics(fM_AVATAR_URL,RowCount)
strSqlAv = "SELECT M_AVATAR_URL FROM " & strMemberTablePrefix & "MEMBERS WHERE MEMBER_ID = " & Topic_Last_Post_Author
Set rsLPost=my_Conn.Execute(strSqlAv)
If not rsLPost.EOF Then
strLPostAvatar=rsLPost("M_AVATAR_URL")
rsLPost.Close
End If
Set rsLPost=Nothing
' ## Events Calendar Below
blnEvent = False
If not blnCalNoEvents Then
For each ttID in arrTopicID
If cLng(ttID) = cLng(TOPIC_ID) Then
blnEvent = TRUE
Exit For
End If
Next
End If
' ## Events Calendar Above
' ## Poll Below
IsPoll = allActiveTopics(fIS_POLL,RowCount)
If IsPoll = 1 Then
pollLink = "poll=1&"
Else
pollLink = ""
End If
' ## Poll Above
If mLev > 3 Then
ModerateAllowed = "Y"
ElseIf mLev = 3 and ModOfForums <> "" Then
If (strAuthType = "nt") Then
If (chkForumModerator(Forum_ID, Session(strCookieURL & "username")) = "1") Then ModerateAllowed = "Y" Else ModerateAllowed = "N"
Else
If (instr("," & ModOfForums & "," ,"," & Forum_ID & ",") > 0) Then ModerateAllowed = "Y" Else ModerateAllowed = "N"
End If
Else
ModerateAllowed = "N"
End If
If ModerateAllowed = "Y" and Topic_UReplies > 0 Then
Topic_Replies = Topic_Replies + Topic_UReplies
End If
fDisplayCount = fDisplayCount + 1
If currForum <> Forum_ID Then
Response.Write " <tr>" & vbNewLine & _
" <td height=""20"" colspan=""7"" bgcolor=""" & strCategoryCellColor & """ valign=""middle""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strCategoryFontColor & """><a href=""default.asp?CAT_ID=" & Cat_ID & """><font color=""" & strCategoryFontColor & """><b>" & ChkString(Cat_Name,"display") & "</b></font></a> / <a href=""forum.asp?FORUM_ID=" & Forum_ID & """><font color=""" & strCategoryFontColor & """><b>" & ChkString(Forum_Subject,"display") & "</b></font></a></font></td>" & vbNewLine
If (mlev > 0) or (lcase(strNoCookies) = "1") Then
Response.Write " <td align=""center"" bgcolor=""" & strCategoryCellColor & """ nowrap valign=""middle"">" & vbNewLine
If (ModerateAllowed = "Y") or (lcase(strNoCookies) = "1") Then
ForumAdminOptions
Else
If Cat_Status <> 0 and Forum_Status <> 0 Then
ForumMemberOptions
Else
Response.Write " " & vbNewLine
End If
End If
Response.Write " </td>" & vbNewLine
ElseIf (mLev = 3) Then
Response.Write " <td align=""center"" bgcolor=""" & strCategoryCellColor & """ nowrap valign=""middle""> </td>" & vbNewLine
End If
Response.Write " </tr>" & vbNewLine
End If
Response.Write " <tr>" & vbNewLine
Response.Write " <td bgcolor=""" & strForumCellColor & """ align=""center"" valign=""middle"">"
Response.Write "<a href=""topic.asp?TOPIC_ID=" & Topic_ID & """>"
If Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0 Then
If Topic_Status = 2 Then
UnApprovedFound = "Y"
Response.Write getCurrentIcon(strIconFolderUnmoderated,"Topic Not Moderated","hspace=""0""") & "</a>" & vbNewLine
ElseIf Topic_Status = 3 Then
HeldFound = "Y"
Response.Write getCurrentIcon(strIconFolderHold,"Topic on Hold","hspace=""0""") & "</a>" & vbNewLine
' DEM --> end of code Added For topic moderation
' ## Events Calendar Below
ElseIf blnEvent Then
Response.Write getCurrentIcon(strCalIconEvent, strCalEvent,"")
' ## Events Calendar Above
ElseIf lcase(strHotTopic) = "1" and Topic_Replies >= intHotTopicNum Then
Response.Write getCurrentIcon(strIconFolderNewHot,"Hot Topic with New Posts","hspace=""0""") & "</a>" & vbNewLine
ElseIf Topic_Last_Post < lastdate Then
Response.Write getCurrentIcon(strIconFolder,"No New Posts","") & "</a>" & vbNewLine
Else
Response.Write getCurrentIcon(strIconFolderNew,"New Posts","") & "</a>" & vbNewLine
End If
Else
If Cat_Status = 0 Then
strAltText = "Category locked"
ElseIf Forum_Status = 0 Then
strAltText = "Forum locked"
Else
strAltText = "Topic locked"
End If
If Topic_Last_Post < lastdate Then
Response.Write getCurrentIcon(strIconFolderLocked,strAltText,"hspace=""0""")
Else
Response.Write getCurrentIcon(strIconFolderNewLocked,strAltText,"hspace=""0""")
End If
Response.Write "</a>" & vbNewLine
End If
' ## Message Icon Below
Response.Write " </td>" & vbNewLine & _
" <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center"">" & getCurrentIcon(getCurrentMsgIcon(Topic_MsgIcon),"","hspace=""0""") & "</td>" & vbNewLine & _
" <td bgcolor=""" & strForumCellColor & """ valign=""middle""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>"
' ## Message Icon Above
' ## Poll Below
If IsPoll Then Response.Write "Poll: "
' ## Poll Above
Response.Write "<span class=""spnMessageText""><a href=""topic.asp?TOPIC_ID=" & Topic_ID & """>" & ChkString(Topic_Subject,"title") & "</a></span> </font>" & vbNewLine
If strShowPaging = "1" Then
TopicPaging()
End If
Response.Write " </td>" & vbNewLine & _
" <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""><a href=""pop_profile.asp?mode=display&id="& TOPIC_AUTHOR & """><acronym style=""text-decoration:underline; border:none;"" title=""" & Member_Name & """><img src=""" & Member_Avatar & """ height=""50"" width=""50"" /></acronym></a><br /><font face=""" & strDefaultFontFace & """ size=""1"" & strDefaultFontSize & """" color=""" & strForumFontColor & """><span class=""spnMessageText"">" & profileLink(chkString(Member_Name,"display"),Topic_Author) & "</span></font></td>" & vbNewLine
If CLng(Topic_Replies) > 0 Then
response.write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """><span class=""spnMessageText""><acronym title=""Click here to see who has posted in this topic. (" & ChkString(Topic_Subject,"title") & ")""><a href=""JavaScript:openWindow3('pop_posted.asp?" & ArchiveLink & "Topic_ID=" & Topic_ID & "')""" & dWStatus("Who has posted?") & "><font size=""1"">Click to see who commented<br /></font>" & Topic_Replies & "</a></acronym></span></font></td>" & vbNewLine
Else
Response.Write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """>" & Topic_Replies & "</font></td>" & vbNewLine
End If
Response.Write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""> <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """>" & Topic_View_Count & "</font></td>" & vbNewLine
If IsNull(Topic_Last_Post_Author) Then
strLastAuthor = ""
Else
strLastAuthor = "<br />by: <a href=""pop_profile.asp?mode=display&id="& Topic_Last_Post_Author & """><acronym style=""text-decoration:underline; border:none;"" title=""" & Topic_Last_Post_Author_Name & """><img src=""" & strLPostAvatar & """ height=""50"" width=""50"" /></acronym></a>"
If strJumpLastPost = "1" Then strLastAuthor = strLastAuthor & " " & DoLastPostLink
End If
Response.Write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center"" nowrap><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """ color=""" & strForumFontColor & """><b>" & ChkDate(Topic_Last_Post, "</b> " ,true) & strLastAuthor & "</font></td>" & vbNewLine
If (mlev > 0) or (lcase(strNoCookies) = "1") Then
Response.Write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center"" nowrap><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine
If (ModerateAllowed = "Y") or (lcase(strNoCookies) = "1") Then
Call TopicAdminOptions
Else
If Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0 Then
Call TopicMemberOptions
Else
Response.Write " " & vbNewLine
End If
End If
Response.Write " </font></b></td>" & vbNewLine
ElseIf (mLev = 3) Then
Response.Write " <td bgcolor=""" & strForumCellColor & """> </td>" & vbNewLine
End If
Response.Write " </tr>" & vbNewLine
currForum = Forum_ID
Next
If fDisplayCount = 0 Then
Response.Write " <tr>" & vbNewLine & _
" <td colspan=""" & aGetColspan(8,7) & """ bgcolor=""" & strForumCellColor & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><b>No Active Topics Found</b></font></td>" & vbNewLine & _
" </tr>" & vbNewLine
End If
End If
Response.Write " </table>" & vbNewLine & _
" </td>" & vbNewLine & _
" </tr>" & vbNewLine & _
" </table>" & vbNewLine & _
" <table width=""100%"" border=""0"" align=""center"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td align=""left"" width=""50%"">" & vbNewLine & _
" <table>" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td>" & vbNewLine & _
" <p><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>" & vbNewLine & _
" " & getCurrentIcon(strIconFolderNew,"New Posts","align=""absmiddle""") & " New posts since last logon.<br />" & vbNewLine & _
" " & getCurrentIcon(strIconFolder,"Old Posts","align=""absmiddle""") & " Old Posts."
If lcase(strHotTopic) = "1" Then
Response.Write (" (" & getCurrentIcon(strIconFolderHot,"Hot Topic","align=""absmiddle""") & " " & intHotTopicNum & " replies or more.)<br />" & vbNewLine)
end if
Response.Write " " & getCurrentIcon(strIconFolderLocked,"Locked Topic","align=""absmiddle""") & " Locked topic.<br />" & vbNewLine
If HeldFound = "Y" Then
Response.Write " " & getCurrentIcon(strIconFolderHold,"Held Topic","align=""absmiddle""") & " Held Topic.<br />" & vbNewLine
End If
If UnapprovedFound = "Y" Then
Response.Write " " & getCurrentIcon(strIconFolderUnmoderated,"UnModerated Topic","align=""absmiddle""") & " UnModerated Topic.<br />" & vbNewLine
End If
Response.Write " </font></p></td>" & vbNewLine & _
" </tr>" & vbNewLine & _
" </table>" & vbNewLine & _
" </td>" & vbNewLine & _
" <td align=""right"" valign=""top"" width=""50%"" nowrap>" & vbNewLine
%>
<!--#INCLUDE FILE="inc_jump_to.asp" -->
<%
Response.Write " </td></tr><tr>" & vbNewline & _
" <td colspan=""8"" bgColor=""" & strForumCellColor & """>" & vbNewline & _
" <table width=""100%"" border=""1"" style=""border-collapse:collapse;"" cellpadding=""4"" cellspacing=""1"" bgColor=""" & strTableBorderColor & """>" & vbNewline & _
" <tr>" & vbNewline
Call DisplayBirthdays(30,0)
Response.Write " </tr>" & vbNewLine & _
" </table></td></tr>" & vbNewLine & _
" <script language=""javascript"" type=""text/javascript"">" & vbNewLine & _
" <!--" & vbNewLine & _
" if (document.ReloadFrm.RefreshTime.options[document.ReloadFrm.RefreshTime.selectedIndex].value > 0) {" & vbNewline & _
" reloadTime = 60000 * document.ReloadFrm.RefreshTime.options[document.ReloadFrm.RefreshTime.selectedIndex].value" & vbNewLine & _
" self.setInterval('autoReload()', 60000 * document.ReloadFrm.RefreshTime.options[document.ReloadFrm.RefreshTime.selectedIndex].value)" & vbNewLine & _
" }" & vbNewLine & _
" //-->" & vbNewLine & _
" </script>" & vbNewLine
WriteFooter
Response.End
Sub ForumAdminOptions()
If (ModerateAllowed = "Y") or (lcase(strNoCookies) = "1") Then
If Cat_Status = 0 Then
If mLev > 3 Then
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Category&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconFolderUnlocked,"Un-Lock Category","") & "</a>" & vbNewLine
Else
Response.Write " " & getCurrentIcon(strIconFolderLocked,"Category Locked","") & vbNewLine
End If
Else
If Forum_Status <> 0 Then
Response.Write " <a href=""JavaScript:openWindow('pop_lock.asp?mode=Forum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconFolderLocked,"Lock Forum","") & "</a>" & vbNewLine
Else
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Forum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconFolderUnlocked,"Un-Lock Forum","") & "</a>" & vbNewLine
End If
End If
If (Cat_Status <> 0 and Forum_Status <> 0) or (ModerateAllowed = "Y") Then
Response.Write " <a href=""post.asp?method=EditForum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "&type=0"">" & getCurrentIcon(strIconFolderPencil,"Edit Forum Properties","hspace=""0""") & "</a>" & vbNewLine
End If
If mLev > 3 or lcase(strNoCookies) = "1" Then Response.Write(" <a href=""JavaScript:openWindow('pop_delete.asp?mode=Forum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconFolderDelete,"Delete Forum","") & "</a>" & vbNewLine)
Response.Write " <a href=""post.asp?method=Topic&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconFolderNewTopic,"New Topic","") & "</a>" & vbNewLine
If (strSubscription < 4 and strSubscription > 0) and (CatSubscription > 0) and ForumSubscription = 1 and strEmail = 1 Then
If InArray(strForumSubs, Forum_ID) Then
Response.Write ShowSubLink ("U", Cat_ID, Forum_ID, 0, "N")
ElseIf strBoardSubs <> "Y" and not(InArray(strCatSubs,Cat_ID)) Then
Response.Write ShowSubLink ("S", Cat_ID, Forum_ID, 0, "N")
End If
End If
End If
End Sub
Sub ForumMemberOptions()
If (mlev > 0) Then
Response.Write " <a href=""post.asp?method=Topic&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconFolderNewTopic,"New Topic","") & "</a>" & vbNewLine
If (strSubscription > 0 and strSubscription < 4) and CatSubscription > 0 and ForumSubscription = 1 and strEmail = 1 Then
If InArray(strForumSubs, Forum_ID) Then
Response.Write ShowSubLink ("U", Cat_ID, Forum_ID, 0, "N")
ElseIf strBoardSubs <> "Y" and not(InArray(strCatSubs,Cat_ID)) Then
Response.Write ShowSubLink ("S", Cat_ID, Forum_ID, 0, "N")
End If
End If
End If
End Sub
Sub TopicAdminOptions()
If Cat_Status = 0 Then
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Category&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconUnlock,"Un-Lock Category","hspace=""0""") & "</a>" & vbNewLine
ElseIf Forum_Status = 0 Then
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Forum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconUnlock,"Un-Lock Forum","hspace=""0""") & "</a>" & vbNewLine
ElseIf Topic_Status <> 0 Then
Response.Write " <a href=""JavaScript:openWindow('pop_lock.asp?mode=Topic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconLock,"Lock Topic","hspace=""0""") & "</a>" & vbNewLine
Else
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Topic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconUnlock,"Un-Lock Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If (ModerateAllowed = "Y") or (Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0) Then
' ## Poll Below
Response.Write " <a href=""post.asp?" & pollLink & "method=EditTopic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&auth=" & Topic_Author & """>" & getCurrentIcon(strIconPencil,"Edit Topic","hspace=""0""") & "</a>" & vbNewLine
End If
Response.Write " <a href=""JavaScript:openWindow('pop_delete.asp?" & pollLink & "mode=Topic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconTrashcan,"Delete Topic","hspace=""0""") & "</a>" & vbNewLine
' ## Poll Above
If Topic_Status <= 1 Then
Response.Write " <a href=""post.asp?method=Reply&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconReplyTopic,"Reply to Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If Topic_Status > 1 Then
TopicString = "TOPIC_ID=" & Topic_ID & "&CAT_ID=" & Cat_ID & "&FORUM_ID=" & Forum_ID
Response.Write " <a href=""JavaScript:openWindow('pop_moderate.asp?" & TopicString & "')"">" & getCurrentIcon(strIconFolderModerate,"Approve/Hold/Reject this Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If (strSubscription < 4 and strSubscription > 0) and (CatSubscription > 0) and ForumSubscription > 0 and strEmail = 1 Then
If InArray(strTopicSubs, Topic_ID) Then
Response.Write " " & ShowSubLink ("U", Cat_ID, Forum_ID, Topic_ID, "N")
ElseIf strBoardSubs <> "Y" and not(InArray(strForumSubs,Forum_ID) or InArray(strCatSubs,Cat_ID)) Then
Response.Write " " & ShowSubLink ("S", Cat_ID, Forum_ID, Topic_ID, "N")
End If
End If
End Sub
Sub TopicMemberOptions()
If (Topic_Status > 0 and Topic_Author = MemberID) or (ModerateAllowed = "Y") Then
' ## Poll Below
Response.Write " <a href=""post.asp?" & pollLink & "method=EditTopic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconPencil,"Edit Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If (Topic_Status > 0 and Topic_Author = MemberID and Topic_Replies = 0) or (ModerateAllowed = "Y") Then
Response.Write " <a href=""JavaScript:openWindow('pop_delete.asp?" & pollLink & "mode=Topic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconTrashcan,"Delete Topic","hspace=""0""") & "</a>" & vbNewLine
' ## Poll Above
End If
If Topic_Status <= 1 Then
Response.Write " <a href=""post.asp?method=Reply&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconReplyTopic,"Reply to Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If (strSubscription < 4 and strSubscription > 0) and (CatSubscription > 0) and ForumSubscription > 0 and strEmail = 1 Then
If InArray(strTopicSubs, Topic_ID) Then
Response.Write " " & ShowSubLink ("U", Cat_ID, Forum_ID, Topic_ID, "N")
ElseIf strBoardSubs <> "Y" and not(InArray(strForumSubs,Forum_ID) or InArray(strCatSubs,Cat_ID)) Then
Response.Write " " & ShowSubLink ("S", Cat_ID, Forum_ID, Topic_ID, "N")
End If
End If
End Sub
Sub TopicPaging()
mxpages = (Topic_Replies / strPageSize)
If mxPages <> cLng(mxPages) Then
mxpages = int(mxpages) + 1
End If
If mxpages > 1 Then
Response.Write " <table border=""0"" cellspacing=""0"" cellpadding=""0"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td valign=""bottom""><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>" & getCurrentIcon(strIconPosticon,"","align=""absmiddle""") & "</font></td>" & vbNewLine
For counter = 1 to mxpages
ref = " <td align=""right"" valign=""bottom"" bgcolor=""" & strForumCellColor & """><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>"
If ((mxpages > 9) and (mxpages > strPageNumberSize)) or ((counter > 9) and (mxpages < strPageNumberSize)) Then
ref = ref & " "
End If
ref = ref & widenum(counter) & "<span class=""spnMessageText""><a href=""topic.asp?"
ref = ref & ArchiveLink
ref = ref & "TOPIC_ID=" & Topic_ID
ref = ref & "&whichpage=" & counter
ref = ref & """>" & counter & "</a></span></font></td>"
Response.Write ref & vbNewLine
If counter mod strPageNumberSize = 0 and counter < mxpages Then
Response.Write " </tr>" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td> </td>" & vbNewLine
End If
Next
Response.Write " </tr>" & vbNewLine & _
" </table>" & vbNewLine
End If
End Sub
Function DoLastPostLink()
If Topic_Replies < 1 or Topic_Last_Post_Reply_ID = 0 Then
DoLastPostLink = "<a href=""topic.asp?" & ArchiveLink & "TOPIC_ID=" & Topic_ID & """>" & getCurrentIcon(strIconLastpost,"Jump to Last Post","align=""absmiddle""") & "</a>"
ElseIf Topic_Last_Post_Reply_ID <> 0 Then
PageLink = "whichpage=-1&"
AnchorLink = "&REPLY_ID="
DoLastPostLink = "<a href=""topic.asp?" & ArchiveLink & PageLink & "TOPIC_ID=" & Topic_ID & AnchorLink & Topic_Last_Post_Reply_ID & """>" & getCurrentIcon(strIconLastpost,"Jump to Last Post","align=""absmiddle""") & "</a>"
Else
DoLastPostLink = ""
End If
End Function
function aGetColspan(lIN, lOUT)
If (mlev > 0 or strNoCookies = "1") Then
lOut = lOut + 1
End If
If lOut > lIn Then
aGetColspan = lIN
Else
aGetColspan = lOUT
End If
End Function
Sub DoHideCategory(intCatId)
HideForumCat = strUniqueID & "HideCat" & intCatId
If Request.QueryString(HideForumCat) = "Y" Then
Response.Cookies(HideForumCat) = "Y"
Response.Cookies(HideForumCat).Expires = dateAdd("d", 30, strForumTimeAdjust)
Else
If Request.QueryString(HideForumCat) = "N" Then
Response.Cookies(HideForumCat) = "N"
Response.Cookies(HideForumCat).Expires = dateadd("d", -2, strForumTimeAdjust)
End If
End If
End sub
%>
|
MaGraham |
Posted - 20 January 2014 : 23:06:52 I've made a few changes to my active.asp (with Carefree's help) since last posting a copy of it here so I am going to post it again.
<%
'###############################################################################
'##
'## Snitz Forums 2000 v3.4.07
'##
'###############################################################################
'##
'## Copyright © 2000-09 Michael Anderson, Pierre Gorissen,
'## Huw Reddick and Richard Kinser
'##
'## This program is free. You can redistribute and/or modify it under the
'## terms of the GNU General Public License as published by the Free Software
'## Foundation; either version 2 or (at your option) any later version.
'##
'## All copyright notices regarding Snitz Forums 2000 must remain intact in
'## the scripts and in the HTML output. The "powered by" text/logo with a
'## link back to http://forum.snitz.com in the footer of the pages MUST
'## remain visible when the pages are viewed on the internet or intranet.
'##
'## This program is distributed in the hope that it will be useful but
'## WITHOUT ANY WARRANTY; without even an 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:
'##
'## Free Software Foundation, Inc.
'## 59 Temple Place, Suite 330
'## Boston, MA 02111-1307
'##
'## Support can be obtained from our support forums at:
'##
'## http://forum.snitz.com
'##
'## Correspondence and marketing questions can be sent to:
'##
'## manderson@snitz.com
'##
'###############################################################################
%>
<!--#INCLUDE FILE="config.asp"-->
<!--#INCLUDE FILE="inc_sha256.asp" -->
<!--#INCLUDE FILE="inc_header.asp" -->
<!--#INCLUDE FILE="inc_func_secure.asp" -->
<!--#INCLUDE FILE="inc_func_chknew.asp" -->
<!--#INCLUDE FILE="inc_subscription.asp" -->
<!--#INCLUDE FILE="inc_moderation.asp" -->
<!--#INCLUDE FILE="inc_birthdays.asp" -->
<%
nRefreshTime = Request.Cookies(strCookieURL & "Reload")
If Request.Form("cookie") = "1" Then
If strSetCookieToForum = 1 Then
Response.Cookies(strCookieURL & "Reload").Path = strCookieURL
End If
Response.Cookies(strCookieURL & "Reload") = Request.Form("RefreshTime")
Response.Cookies(strCookieURL & "Reload").Expires = strForumTimeAdjust + 365
nRefreshTime = Request.Form("RefreshTime")
End If
If nRefreshTime = "" Then
nRefreshTime = 10
End If
ActiveSince = Request.Cookies(strCookieURL & "ActiveSince")
If Request.Form("cookie") = "2" Then
ActiveSince = Request.Form("ShowSinceDateTime")
If strSetCookieToForum = 1 Then
Response.Cookies(strCookieURL & "ActiveSince").Path = strCookieURL
End If
Response.Cookies(strCookieURL & "ActiveSince") = ActiveSince
End If
Dim ModerateAllowed
Dim HasHigherSub
Dim HeldFound, UnApprovedFound, UnModeratedPosts, UnModeratedFPosts
Dim canView
HasHigherSub = false
Select Case ActiveSince
Case "LastVisit"
lastDate = ""
Case "LastFifteen"
lastDate = DateToStr(DateAdd("n",-15,strForumTimeAdjust))
Case "LastThirty"
lastDate = DateToStr(DateAdd("n",-30,strForumTimeAdjust))
Case "LastFortyFive"
lastDate = DateToStr(DateAdd("n",-45,strForumTimeAdjust))
Case "LastHour"
lastDate = DateToStr(DateAdd("h",-1,strForumTimeAdjust))
Case "Last2Hours"
lastDate = DateToStr(DateAdd("h",-2,strForumTimeAdjust))
Case "Last6Hours"
lastDate = DateToStr(DateAdd("h",-6,strForumTimeAdjust))
Case "Last12Hours"
lastDate = DateToStr(DateAdd("h",-12,strForumTimeAdjust))
Case "LastDay"
lastDate = DateToStr(DateAdd("d",-1,strForumTimeAdjust))
Case "Last2Days"
lastDate = DateToStr(DateAdd("d",-2,strForumTimeAdjust))
Case "LastWeek"
lastDate = DateToStr(DateAdd("ww",-1,strForumTimeAdjust))
Case "Last2Weeks"
lastDate = DateToStr(DateAdd("ww",-2,strForumTimeAdjust))
Case "LastMonth"
lastDate = DateToStr(DateAdd("m",-1,strForumTimeAdjust))
Case "Last2Months"
lastDate = DateToStr(DateAdd("m",-2,strForumTimeAdjust))
Case Else
lastDate = ""
End Select
Response.Write " <script language=""JavaScript"" type=""text/javascript"">" & vbNewLine & _
" <!--" & vbNewLine & _
" function autoReload() { document.ReloadFrm.submit() }" & vbNewLine & _
" function SetLastDate() { document.LastDateFrm.submit() }" & vbNewLine & _
" function jumpTo(s) { if (s.selectedIndex != 0) location.href = s.options[s.selectedIndex].value;return 1;}" & vbNewLine & _
" //defaultStatus = ""You last loaded this page on " & chkDate(DateToStr(strForumTimeAdjust)," ",true) & " (Forum Time)""" & vbNewLine & _
" // -->" & vbNewLine & _
" </script>" & vbNewLine
If IsEmpty(Session(strCookieURL & "last_here_date")) Then
Session(strCookieURL & "last_here_date") = ReadLastHereDate(strDBNTUserName)
End If
If lastDate = "" Then
lastDate = DateToStr(DateAdd("d",-1,strForumTimeAdjust))
End If
If Request.Form("AllRead") = "Y" Then
lastDate = ChkString(Request.Form("BuildTime"),"SQLString")
'## The redundant line below is necessary, don't delete it.
Session(strCookieURL & "last_here_date") = lastDate
Session(strCookieURL & "last_here_date") = lastDate
UpdateLastHereDate lastDate,strDBNTUserName
ActiveSince = ""
End If
If strModeration = "1" and mLev > 2 Then
UnModeratedPosts = CheckForUnmoderatedPosts("BOARD", 0, 0, 0)
End If
Dim strSubString, strSubArray, strBoardSubs, strCatSubs, strForumSubs, strTopicSubs
If MySubCount > 0 Then
strSubString = PullSubscriptions(0,0,0)
strSubArray = Split(strSubString,";")
If uBound(strSubArray) < 0 Then
strBoardSubs = ""
strCatSubs = ""
strForumSubs = ""
strTopicSubs = ""
Else
strBoardSubs = strSubArray(0)
strCatSubs = strSubArray(1)
strForumSubs = strSubArray(2)
strTopicSubs = strSubArray(3)
End If
End If
If mlev = 3 Then
strSql = "SELECT FORUM_ID FROM " & strTablePrefix & "MODERATOR " & _
" WHERE MEMBER_ID = " & MemberID
Set rsMod = Server.CreateObject("ADODB.Recordset")
rsMod.Open strSql, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText
If rsMod.EOF Then
recModCount = ""
Else
allModData = rsMod.GetRows(adGetRowsRest)
recModCount = UBound(allModData,2)
End If
RsMod.Close
Set RsMod = Nothing
If recModCount <> "" Then
For x = 0 to recModCount
If x = 0 Then
ModOfForums = allModData(0,x)
Else
ModOfForums = ModOfForums & "," & allModData(0,x)
End If
Next
Else
ModOfForums = ""
End If
Else
ModOfForums = ""
End If
If strPrivateForums = "1" and mLev < 4 Then
allAllowedForums = ""
allowSql = "SELECT FORUM_ID, F_SUBJECT, F_PRIVATEFORUMS, F_PASSWORD_NEW"
allowSql = allowSql & " FROM " & strTablePrefix & "FORUM"
allowSql = allowSql & " WHERE F_TYPE = 0"
allowSql = allowSql & " ORDER BY FORUM_ID"
Set rsAllowed = Server.CreateObject("ADODB.Recordset")
rsAllowed.Open allowSql, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText
If rsAllowed.EOF Then
recAllowedCount = ""
Else
allAllowedData = rsAllowed.GetRows(adGetRowsRest)
recAllowedCount = UBound(allAllowedData,2)
End If
rsAllowed.Close
Set rsAllowed = Nothing
If recAllowedCount <> "" Then
fFORUM_ID = 0
fF_SUBJECT = 1
fF_PRIVATEFORUMS = 2
fF_PASSWORD_NEW = 3
For RowCount = 0 to recAllowedCount
Forum_ID = allAllowedData(fFORUM_ID,RowCount)
Forum_Subject = allAllowedData(fF_SUBJECT,RowCount)
Forum_PrivateForums = allAllowedData(fF_PRIVATEFORUMS,RowCount)
Forum_FPasswordNew = allAllowedData(fF_PASSWORD_NEW,RowCount)
If mLev > 3 Then
ModerateAllowed = "Y"
ElseIf mLev = 3 and ModOfForums <> "" Then
If (strAuthType = "nt") Then
If (chkForumModerator(Forum_ID, Session(strCookieURL & "username")) = "1") Then ModerateAllowed = "Y" Else ModerateAllowed = "N"
Else
If (instr("," & ModOfForums & "," ,"," & Forum_ID & ",") > 0) Then ModerateAllowed = "Y" Else ModerateAllowed = "N"
End If
Else
ModerateAllowed = "N"
End If
If chkForumAccessNew(Forum_PrivateForums,Forum_FPasswordNew,Forum_Subject,Forum_ID,MemberID) = true Then
If allAllowedForums = "" Then
allAllowedForums = Forum_ID
Else
allAllowedForums = allAllowedForums & "," & Forum_ID
End If
End If
Next
End If
If allAllowedForums = "" Then allAllowedForums = 0
End If
' ## Msg Icon & Poll Below
strSql = "SELECT F.FORUM_ID, " & _
"F.F_SUBJECT, " & _
"F.F_SUBSCRIPTION, " & _
"F.F_STATUS, " & _
"C.CAT_ID, " & _
"C.CAT_NAME, " & _
"C.CAT_SUBSCRIPTION, " & _
"C.CAT_STATUS, " & _
"T.T_STATUS, " & _
"T.T_VIEW_COUNT, " & _
"T.TOPIC_ID, " & _
"T.T_ISPOLL, " &_
"T.T_SUBJECT, " & _
"T.T_AUTHOR, " & _
"T.T_REPLIES, " & _
"T.T_UREPLIES, " & _
"M.M_NAME, " & _
"T.T_LAST_POST_AUTHOR, " & _
"T.T_LAST_POST, " & _
"T.T_LAST_POST_REPLY_ID, " & _
"MEMBERS_1.M_NAME AS LAST_POST_AUTHOR_NAME, " & _
"T.T_MSGICON, " & _
"F.F_PRIVATEFORUMS, " & _
"F.F_PASSWORD_NEW, " & _
"M.M_AVATAR_URL " & _
"FROM " & strMemberTablePrefix & "MEMBERS M, " & _
strTablePrefix & "FORUM F, " & _
strTablePrefix & "TOPICS T, " & _
strTablePrefix & "CATEGORY C, " & _
strMemberTablePrefix & "MEMBERS MEMBERS_1 " & _
"WHERE T.T_LAST_POST_AUTHOR = MEMBERS_1.MEMBER_ID "
' ## Msg Icon & Poll Above
If strPrivateForums = "1" and mLev < 4 Then
strSql = strSql & " AND F.FORUM_ID IN (" & allAllowedForums & ") "
End If
' ## UserGroup Below
strDeniedForums = Session(strCookieURL & "DeniedForums" & MemberID)
If strDeniedForums <> "" and strDeniedForums <> "-1" Then
strSql = strSql & " AND F.FORUM_ID NOT IN(" & Session(strCookieURL & "DeniedForums" & MemberID) & ") "
End If
' ## UserGroup Above
strSql = strSql & "AND F.F_TYPE = 0 " & _
"AND F.FORUM_ID = T.FORUM_ID " & _
"AND C.CAT_ID = T.CAT_ID " & _
"AND M.MEMBER_ID = T.T_AUTHOR " & _
"AND (T.T_LAST_POST > '" & lastDate & "'"
If mlev <> 4 Then
strSql = strSql & " AND ((T.T_AUTHOR <> " & MemberID &_
" AND T.T_STATUS < 2)"
If mlev = 3 and ModOfForums <> "" Then
strSql = strSql & " OR T.FORUM_ID IN (" & ModOfForums & ") "
End If
strSql = strSql & " OR T.T_AUTHOR = " & MemberID & ")"
End If
If Group > 1 and strGroupCategories = "1" Then
strSql = strSql & " AND (C.CAT_ID = 0"
If recGroupCatCount <> "" Then
For iGroupCat = 0 to recGroupCatCount
strSql = strSql & " or C.CAT_ID = " & allGroupCatData(1, iGroupCat)
Next
strSql = strSql & ")"
Else
strSql = strSql & ")"
End If
End If
strSql = strSql & ") "
strSql = strSql & " ORDER BY C.CAT_ORDER, C.CAT_NAME, F.F_ORDER, F.F_SUBJECT, T.T_LAST_POST DESC "
Set rs = Server.CreateObject("ADODB.Recordset")
If strDBType <> "mysql" Then rs.cachesize = 50
rs.Open strSql, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText
If rs.EOF Then
recActiveTopicsCount = ""
Else
allActiveTopics = rs.GetRows(adGetRowsRest)
recActiveTopicsCount = UBound(allActiveTopics,2)
rs.Close
End If
Set rs = Nothing
' ## Events Calendar Below
strSQL = "SELECT T.TOPIC_ID FROM " & strTablePrefix & "TOPICS AS T INNER JOIN " & strTablePrefix & "CAL_EVENTS AS C ON T.TOPIC_ID = C.TOPIC_ID WHERE T.T_LAST_POST > '" & lastDate & "' GROUP BY T.TOPIC_ID"
Set rsCal = Server.CreateObject("ADODB.Recordset")
rsCal.Open StrSql, My_conn
If not rsCal.EOF Then
arrTopicID = rsCal.GetRows
rsCal.Close
Else
blnCalNoEvents = TRUE
End If
Set rsCal = Nothing
' ## Events Calendar Above
Response.Write " <table width=""100%"" border=""0"" cellspacing=""0"" cellpadding=""0"" align=""center"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <form name=""LastDateFrm"" action=""active.asp"" method=""post""><td>" & vbNewLine & _
" <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine & _
" " & getCurrentIcon(strIconFolderOpen,"","") & " <a href=""default.asp"">COMMUNITY HOME</a><br />" & vbNewLine & _
" " & getCurrentIcon(strIconBar,"","") & getCurrentIcon(strIconFolderOpenTopic,"","") & " " & _
"Active Topics Since " & vbNewLine
Response.Write " <select name=""ShowSinceDateTime"" size=""1"" onchange=""SetLastDate();"">" & vbNewLine & _
" <option value=""LastVisit""" & "nbsp;Last Visit on " & ChkDate(Session(strCookieURL & "last_here_date"),"",true) & " </option>" & vbNewLine & _
" <option value=""LastFifteen""" & chkSelect(ActiveSince,"LastFifteen") & "> Last 15 minutes</option>" & vbNewLine & _
" <option value=""LastThirty""" & chkSelect(ActiveSince,"LastThirty") & "> Last 30 minutes</option>" & vbNewLine & _
" <option value=""LastFortyFive""" & chkSelect(ActiveSince,"LastFortyFive") & "> Last 45 minutes</option>" & vbNewLine & _
" <option value=""LastHour""" & chkSelect(ActiveSince,"LastHour") & "> Last Hour</option>" & vbNewLine & _
" <option value=""Last2Hours""" & chkSelect(ActiveSince,"Last2Hours") & "> Last 2 Hours</option>" & vbNewLine & _
" <option value=""Last6Hours""" & chkSelect(ActiveSince,"Last6Hours") & "> Last 6 Hours</option>" & vbNewLine & _
" <option value=""Last12Hours""" & chkSelect(ActiveSince,"Last12Hours") & "> Last 12 Hours</option>" & vbNewLine & _
" <option value=""LastDay""" & chkSelect(ActiveSince,"LastDay")
If ActiveSince = "LastDay" or ActiveSince = "" Then
Response.Write " selected"
End If
Response.Write "> Yesterday</option>" & vbNewLine & _
" <option value=""Last2Days""" & chkSelect(ActiveSince,"Last2Days") & "> Last 2 Days</option>" & vbNewLine & _
" <option value=""LastWeek""" & chkSelect(ActiveSince,"LastWeek") & "> Last Week</option>" & vbNewLine & _
" <option value=""Last2Weeks""" & chkSelect(ActiveSince,"Last2Weeks") & "> Last 2 Weeks</option>" & vbNewLine & _
" <option value=""LastMonth""" & chkSelect(ActiveSince,"LastMonth") & "> Last Month</option>" & vbNewLine & _
" <option value=""Last2Months""" & chkSelect(ActiveSince,"Last2Months") & "> Last 2 Months</option>" & vbNewLine & _
" </select>" & vbNewLine & _
" <input type=""hidden"" name=""Cookie"" value=""2"">" & vbNewLine & _
" </font>" & vbNewLine & _
" </td>" & vbNewLine & _
" </form>" & vbNewLine & _
" <td align=""center""> </td>" & vbNewLine & _
" <form name=""ReloadFrm"" action=""active.asp"" method=""post"">" & vbNewLine & _
" <td align=""right"">" & vbNewLine & _
" <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & _
" <br />" & vbNewLine & _
" <select name=""RefreshTime"" size=""1"" onchange=""autoReload();"">" & vbNewLine & _
" <option value=""0""" & chkSelect(nRefreshTime,0) & ">Don't reload automatically</option>" & vbNewLine & _
" <option value=""1""" & chkSelect(nRefreshTime,1) & ">Reload page every minute</option>" & vbNewLine & _
" <option value=""2""" & chkSelect(nRefreshTime,2) & ">Reload page every 2 minutes</option>" & vbNewLine & _
" <option value=""5""" & chkSelect(nRefreshTime,5) & ">Reload page every 5 minutes</option>" & vbNewLine & _
" <option value=""10""" & chkSelect(nRefreshTime,10) & ">Reload page every 10 minutes</option>" & vbNewLine & _
" <option value=""15""" & chkSelect(nRefreshTime,15) & ">Reload page every 15 minutes</option>" & vbNewLine & _
" </select>" & vbNewLine & _
" <input type=""hidden"" name=""Cookie"" value=""1"">" & vbNewLine & _
" </font>" & vbNewLine & _
" </td>" & vbNewLine & _
" </form>" & vbNewLine & _
" </tr>" & vbNewLine & _
" </table>" & vbNewLine & _
" <font size=""" & strFooterFontSize & """><br /></font>" & vbNewLine & _
" <table border=""0"" width=""100%"" cellspacing=""0"" cellpadding=""0"" align=""center"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td bgcolor=""" & strTableBorderColor & """>" & vbNewLine & _
" <table border=""0"" width=""100%"" cellspacing=""1"" cellpadding=""4"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """ valign=""middle""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>" & vbNewLine
If recActiveTopicsCount <> "" and (mLev > 0) Then
Response.Write " <form name=""MarkRead"" action=""active.asp"" method=""post"" style=""display:inline"">" & vbNewLine & _
" <input type=""hidden"" name=""AllRead"" value=""Y"">" & vbNewLine & _
" <input type=""hidden"" name=""BuildTime"" value=""" & DateToStr(strForumTimeAdjust) & """>" & vbNewLine & _
" <input type=""hidden"" name=""Cookie"" value=""2"">" & vbNewLine & _
" <acronym style=""border:none; text-decoration:none"" title=""Mark all topics as read""><input type=""image"" src=""" & strImageUrl & "icon_topic_all_read.png"" value=""Mark all read"" id=""submit1"" name=""Mark all topics as read"" border=""0""" & dWStatus("Mark all topics as read") & "></acronym></font></td>" & vbNewLine & _
" </form>" & vbNewLine
Else
Response.Write " </font></td>" & vbNewLine
End If
Response.Write " <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """> </font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Topic</font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Author</font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Comments</font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Read</font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Last Poster</font></b></td>" & vbNewLine
If (mlev > 0) or (lcase(strNoCookies) = "1") Then
Response.Write " <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>"
If (mLev > 2) or (lcase(strNoCookies) = "1") Then
If UnModeratedPosts > 0 Then
UnModeratedFPosts = 0
Response.Write "<a href=""moderate.asp"">" & getCurrentIcon(strIconFolderModerate,"View All UnModerated Posts","hspace=""0""") & "</a>"
Else
Response.Write(" ")
End If
Else
Response.Write(" ")
End If
Response.Write "</font></b></td>" & vbNewLine
End If
Response.Write " </tr>" & vbNewLine
If recActiveTopicsCount = "" Then
Response.Write " <tr>" & vbNewLine & _
" <td colspan=""8"" bgcolor=""" & strForumCellColor & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """><b>No Active Topics Found</b></font></td>" & vbNewLine & _
" </tr>" & vbNewLine
Else
currForum = 0
fDisplayCount = 0
canAccess = 0
fFORUM_ID = 0
fF_SUBJECT = 1
fF_SUBSCRIPTION = 2
fF_STATUS = 3
fCAT_ID = 4
fCAT_NAME = 5
fCAT_SUBSCRIPTION = 6
fCAT_STATUS = 7
fT_STATUS = 8
fT_VIEW_COUNT = 9
fTOPIC_ID = 10
' ## Poll Below
fIS_POLL = 11
' ## Poll Above
fT_SUBJECT = 12
fT_AUTHOR = 13
fT_REPLIES = 14
fT_UREPLIES = 15
fM_NAME = 16
fT_LAST_POST_AUTHOR = 17
fT_LAST_POST = 18
fT_LAST_POST_REPLY_ID = 19
fLAST_POST_AUTHOR_NAME = 20
fT_MSGICON = 21
fF_PRIVATEFORUMS = 22
fF_PASSWORD_NEW = 23
fM_AVATAR_URL = 24
For RowCount = 0 to recActiveTopicsCount
'## Store all the recordvalues in variables first.
Forum_ID = allActiveTopics(fFORUM_ID,RowCount)
Forum_Subject = allActiveTopics(fF_SUBJECT,RowCount)
ForumSubscription = allActiveTopics(fF_SUBSCRIPTION,RowCount)
Forum_Status = allActiveTopics(fF_STATUS,RowCount)
Cat_ID = allActiveTopics(fCAT_ID,RowCount)
Cat_Name = allActiveTopics(fCAT_NAME,RowCount)
CatSubscription = allActiveTopics(fCAT_SUBSCRIPTION,RowCount)
Cat_Status = allActiveTopics(fCAT_STATUS,RowCount)
Topic_Status = allActiveTopics(fT_STATUS,RowCount)
Topic_View_Count = allActiveTopics(fT_VIEW_COUNT,RowCount)
Topic_ID = allActiveTopics(fTOPIC_ID,RowCount)
Topic_Subject = allActiveTopics(fT_SUBJECT,RowCount)
Topic_Author = allActiveTopics(fT_AUTHOR,RowCount)
Topic_Replies = allActiveTopics(fT_REPLIES,RowCount)
Topic_UReplies = allActiveTopics(fT_UREPLIES,RowCount)
Member_Name = allActiveTopics(fM_NAME,RowCount)
Topic_Last_Post_Author = allActiveTopics(fT_LAST_POST_AUTHOR,RowCount)
Topic_Last_Post = allActiveTopics(fT_LAST_POST,RowCount)
Topic_Last_Post_Reply_ID = allActiveTopics(fT_LAST_POST_REPLY_ID,RowCount)
Topic_Last_Post_Author_Name = chkString(allActiveTopics(fLAST_POST_AUTHOR_NAME,RowCount),"display")
Topic_MsgIcon = allActiveTopics(fT_MSGICON,RowCount)
Forum_PrivateForums = allActiveTopics(fF_PRIVATEFORUMS,RowCount)
Forum_FPasswordNew = allActiveTopics(fF_PASSWORD_NEW,RowCount)
Member_Avatar = allActiveTopics(fM_AVATAR_URL,RowCount)
strSqlAv = "SELECT M_AVATAR_URL FROM " & strMemberTablePrefix & "MEMBERS WHERE MEMBER_ID = " & Topic_Last_Post_Author
Set rsLPost=my_Conn.Execute(strSqlAv)
If not rsLPost.EOF Then
strLPostAvatar=rsLPost("M_AVATAR_URL")
rsLPost.Close
End If
Set rsLPost=Nothing
' ## Events Calendar Below
blnEvent = False
If not blnCalNoEvents Then
For each ttID in arrTopicID
If cLng(ttID) = cLng(TOPIC_ID) Then
blnEvent = TRUE
Exit For
End If
Next
End If
' ## Events Calendar Above
' ## Poll Below
IsPoll = allActiveTopics(fIS_POLL,RowCount)
If IsPoll = 1 Then
pollLink = "poll=1&"
Else
pollLink = ""
End If
' ## Poll Above
If mLev > 3 Then
ModerateAllowed = "Y"
ElseIf mLev = 3 and ModOfForums <> "" Then
If (strAuthType = "nt") Then
If (chkForumModerator(Forum_ID, Session(strCookieURL & "username")) = "1") Then ModerateAllowed = "Y" Else ModerateAllowed = "N"
Else
If (instr("," & ModOfForums & "," ,"," & Forum_ID & ",") > 0) Then ModerateAllowed = "Y" Else ModerateAllowed = "N"
End If
Else
ModerateAllowed = "N"
End If
If ModerateAllowed = "Y" and Topic_UReplies > 0 Then
Topic_Replies = Topic_Replies + Topic_UReplies
End If
fDisplayCount = fDisplayCount + 1
If currForum <> Forum_ID Then
Response.Write " <tr>" & vbNewLine & _
" <td height=""20"" colspan=""7"" bgcolor=""" & strCategoryCellColor & """ valign=""middle""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strCategoryFontColor & """><a href=""default.asp?CAT_ID=" & Cat_ID & """><font color=""" & strCategoryFontColor & """><b>" & ChkString(Cat_Name,"display") & "</b></font></a> / <a href=""forum.asp?FORUM_ID=" & Forum_ID & """><font color=""" & strCategoryFontColor & """><b>" & ChkString(Forum_Subject,"display") & "</b></font></a></font></td>" & vbNewLine
If (mlev > 0) or (lcase(strNoCookies) = "1") Then
Response.Write " <td align=""center"" bgcolor=""" & strCategoryCellColor & """ nowrap valign=""middle"">" & vbNewLine
If (ModerateAllowed = "Y") or (lcase(strNoCookies) = "1") Then
ForumAdminOptions
Else
If Cat_Status <> 0 and Forum_Status <> 0 Then
ForumMemberOptions
Else
Response.Write " " & vbNewLine
End If
End If
Response.Write " </td>" & vbNewLine
ElseIf (mLev = 3) Then
Response.Write " <td align=""center"" bgcolor=""" & strCategoryCellColor & """ nowrap valign=""middle""> </td>" & vbNewLine
End If
Response.Write " </tr>" & vbNewLine
End If
Response.Write " <tr>" & vbNewLine
Response.Write " <td bgcolor=""" & strForumCellColor & """ align=""center"" valign=""middle"">"
Response.Write "<a href=""topic.asp?TOPIC_ID=" & Topic_ID & """>"
If Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0 Then
If Topic_Status = 2 Then
UnApprovedFound = "Y"
Response.Write getCurrentIcon(strIconFolderUnmoderated,"Topic Not Moderated","hspace=""0""") & "</a>" & vbNewLine
ElseIf Topic_Status = 3 Then
HeldFound = "Y"
Response.Write getCurrentIcon(strIconFolderHold,"Topic on Hold","hspace=""0""") & "</a>" & vbNewLine
' DEM --> end of code Added For topic moderation
' ## Events Calendar Below
ElseIf blnEvent Then
Response.Write getCurrentIcon(strCalIconEvent, strCalEvent,"")
' ## Events Calendar Above
ElseIf lcase(strHotTopic) = "1" and Topic_Replies >= intHotTopicNum Then
Response.Write getCurrentIcon(strIconFolderNewHot,"Hot Topic with New Posts","hspace=""0""") & "</a>" & vbNewLine
ElseIf Topic_Last_Post < lastdate Then
Response.Write getCurrentIcon(strIconFolder,"No New Posts","") & "</a>" & vbNewLine
Else
Response.Write getCurrentIcon(strIconFolderNew,"New Posts","") & "</a>" & vbNewLine
End If
Else
If Cat_Status = 0 Then
strAltText = "Category locked"
ElseIf Forum_Status = 0 Then
strAltText = "Forum locked"
Else
strAltText = "Topic locked"
End If
If Topic_Last_Post < lastdate Then
Response.Write getCurrentIcon(strIconFolderLocked,strAltText,"hspace=""0""")
Else
Response.Write getCurrentIcon(strIconFolderNewLocked,strAltText,"hspace=""0""")
End If
Response.Write "</a>" & vbNewLine
End If
' ## Message Icon Below
Response.Write " </td>" & vbNewLine & _
" <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center"">" & getCurrentIcon(getCurrentMsgIcon(Topic_MsgIcon),"","hspace=""0""") & "</td>" & vbNewLine & _
" <td bgcolor=""" & strForumCellColor & """ valign=""middle""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>"
' ## Message Icon Above
' ## Poll Below
If IsPoll Then Response.Write "Poll: "
' ## Poll Above
Response.Write "<span class=""spnMessageText""><a href=""topic.asp?TOPIC_ID=" & Topic_ID & """>" & ChkString(Topic_Subject,"title") & "</a></span> </font>" & vbNewLine
If strShowPaging = "1" Then
TopicPaging()
End If
Response.Write " </td>" & vbNewLine & _
" <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""><a href=""pop_profile.asp?mode=display&id="& TOPIC_AUTHOR & """><acronym style=""text-decoration:underline; border:none;"" title=""" & Member_Name & """><img src=""" & Member_Avatar & """ height=""50"" width=""50"" /></acronym></a><br /><font face=""" & strDefaultFontFace & """ size=""1"" & strDefaultFontSize & """" color=""" & strForumFontColor & """><span class=""spnMessageText"">" & profileLink(chkString(Member_Name,"display"),Topic_Author) & "</span></font></td>" & vbNewLine
If CLng(Topic_Replies) > 0 Then
response.write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """><span class=""spnMessageText""><acronym title=""Click here to see who has posted in this topic. (" & ChkString(Topic_Subject,"title") & ")""><a href=""JavaScript:openWindow3('pop_posted.asp?" & ArchiveLink & "Topic_ID=" & Topic_ID & "')""" & dWStatus("Who has posted?") & "><font size=""1"">Click to see who commented<br /></font>" & Topic_Replies & "</a></acronym></span></font></td>" & vbNewLine
Else
Response.Write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """>" & Topic_Replies & "</font></td>" & vbNewLine
End If
Response.Write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""> <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """>" & Topic_View_Count & "</font></td>" & vbNewLine
If IsNull(Topic_Last_Post_Author) Then
strLastAuthor = ""
Else
strLastAuthor = "<br />by: <a href=""pop_profile.asp?mode=display&id="& Topic_Last_Post_Author & """><acronym style=""text-decoration:underline; border:none;"" title=""" & Topic_Last_Post_Author_Name & """><img src=""" & strLPostAvatar & """ height=""50"" width=""50"" /></acronym></a>"
If strJumpLastPost = "1" Then strLastAuthor = strLastAuthor & " " & DoLastPostLink
End If
Response.Write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center"" nowrap><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """ color=""" & strForumFontColor & """><b>" & ChkDate(Topic_Last_Post, "</b> " ,true) & strLastAuthor & "</font></td>" & vbNewLine
If (mlev > 0) or (lcase(strNoCookies) = "1") Then
Response.Write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center"" nowrap><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine
If (ModerateAllowed = "Y") or (lcase(strNoCookies) = "1") Then
Call TopicAdminOptions
Else
If Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0 Then
Call TopicMemberOptions
Else
Response.Write " " & vbNewLine
End If
End If
Response.Write " </font></b></td>" & vbNewLine
ElseIf (mLev = 3) Then
Response.Write " <td bgcolor=""" & strForumCellColor & """> </td>" & vbNewLine
End If
Response.Write " </tr>" & vbNewLine
currForum = Forum_ID
Next
If fDisplayCount = 0 Then
Response.Write " <tr>" & vbNewLine & _
" <td colspan=""" & aGetColspan(8,7) & """ bgcolor=""" & strForumCellColor & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><b>No Active Topics Found</b></font></td>" & vbNewLine & _
" </tr>" & vbNewLine
End If
End If
Response.Write " </table>" & vbNewLine & _
" </td>" & vbNewLine & _
" </tr>" & vbNewLine & _
" </table>" & vbNewLine & _
" <table width=""100%"" border=""0"" align=""center"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td align=""left"" width=""50%"">" & vbNewLine & _
" <table>" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td>" & vbNewLine & _
" <p><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>" & vbNewLine & _
" " & getCurrentIcon(strIconFolderNew,"New Posts","align=""absmiddle""") & " New posts since last logon.<br />" & vbNewLine & _
" " & getCurrentIcon(strIconFolder,"Old Posts","align=""absmiddle""") & " Old Posts."
If lcase(strHotTopic) = "1" Then
Response.Write (" (" & getCurrentIcon(strIconFolderHot,"Hot Topic","align=""absmiddle""") & " " & intHotTopicNum & " replies or more.)<br />" & vbNewLine)
end if
Response.Write " " & getCurrentIcon(strIconFolderLocked,"Locked Topic","align=""absmiddle""") & " Locked topic.<br />" & vbNewLine
If HeldFound = "Y" Then
Response.Write " " & getCurrentIcon(strIconFolderHold,"Held Topic","align=""absmiddle""") & " Held Topic.<br />" & vbNewLine
End If
If UnapprovedFound = "Y" Then
Response.Write " " & getCurrentIcon(strIconFolderUnmoderated,"UnModerated Topic","align=""absmiddle""") & " UnModerated Topic.<br />" & vbNewLine
End If
Response.Write " </font></p></td>" & vbNewLine & _
" </tr>" & vbNewLine & _
" </table>" & vbNewLine & _
" </td>" & vbNewLine & _
" <td align=""right"" valign=""top"" width=""50%"" nowrap>" & vbNewLine
%>
<!--#INCLUDE FILE="inc_jump_to.asp" -->
<%
Response.Write " </td></tr><tr>" & vbNewline & _
" <td colspan=""8"" bgColor=""" & strForumCellColor & """>" & vbNewline & _
" <table width=""100%"" border=""1"" style=""border-collapse:collapse;"" cellpadding=""4"" cellspacing=""1"" bgColor=""" & strTableBorderColor & """>" & vbNewline & _
" <tr>" & vbNewline
Call DisplayBirthdays(30,0)
Response.Write " </tr>" & vbNewLine & _
" </table></td></tr>" & vbNewLine & _
" <script language=""javascript"" type=""text/javascript"">" & vbNewLine & _
" <!--" & vbNewLine & _
" if (document.ReloadFrm.RefreshTime.options[document.ReloadFrm.RefreshTime.selectedIndex].value > 0) {" & vbNewline & _
" reloadTime = 60000 * document.ReloadFrm.RefreshTime.options[document.ReloadFrm.RefreshTime.selectedIndex].value" & vbNewLine & _
" self.setInterval('autoReload()', 60000 * document.ReloadFrm.RefreshTime.options[document.ReloadFrm.RefreshTime.selectedIndex].value)" & vbNewLine & _
" }" & vbNewLine & _
" //-->" & vbNewLine & _
" </script>" & vbNewLine
WriteFooter
Response.End
Sub ForumAdminOptions()
If (ModerateAllowed = "Y") or (lcase(strNoCookies) = "1") Then
If Cat_Status = 0 Then
If mLev > 3 Then
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Category&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconFolderUnlocked,"Un-Lock Category","") & "</a>" & vbNewLine
Else
Response.Write " " & getCurrentIcon(strIconFolderLocked,"Category Locked","") & vbNewLine
End If
Else
If Forum_Status <> 0 Then
Response.Write " <a href=""JavaScript:openWindow('pop_lock.asp?mode=Forum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconFolderLocked,"Lock Forum","") & "</a>" & vbNewLine
Else
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Forum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconFolderUnlocked,"Un-Lock Forum","") & "</a>" & vbNewLine
End If
End If
If (Cat_Status <> 0 and Forum_Status <> 0) or (ModerateAllowed = "Y") Then
Response.Write " <a href=""post.asp?method=EditForum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "&type=0"">" & getCurrentIcon(strIconFolderPencil,"Edit Forum Properties","hspace=""0""") & "</a>" & vbNewLine
End If
If mLev > 3 or lcase(strNoCookies) = "1" Then Response.Write(" <a href=""JavaScript:openWindow('pop_delete.asp?mode=Forum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconFolderDelete,"Delete Forum","") & "</a>" & vbNewLine)
Response.Write " <a href=""post.asp?method=Topic&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconFolderNewTopic,"New Topic","") & "</a>" & vbNewLine
If (strSubscription < 4 and strSubscription > 0) and (CatSubscription > 0) and ForumSubscription = 1 and strEmail = 1 Then
If InArray(strForumSubs, Forum_ID) Then
Response.Write ShowSubLink ("U", Cat_ID, Forum_ID, 0, "N")
ElseIf strBoardSubs <> "Y" and not(InArray(strCatSubs,Cat_ID)) Then
Response.Write ShowSubLink ("S", Cat_ID, Forum_ID, 0, "N")
End If
End If
End If
End Sub
Sub ForumMemberOptions()
If (mlev > 0) Then
Response.Write " <a href=""post.asp?method=Topic&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconFolderNewTopic,"New Topic","") & "</a>" & vbNewLine
If (strSubscription > 0 and strSubscription < 4) and CatSubscription > 0 and ForumSubscription = 1 and strEmail = 1 Then
If InArray(strForumSubs, Forum_ID) Then
Response.Write ShowSubLink ("U", Cat_ID, Forum_ID, 0, "N")
ElseIf strBoardSubs <> "Y" and not(InArray(strCatSubs,Cat_ID)) Then
Response.Write ShowSubLink ("S", Cat_ID, Forum_ID, 0, "N")
End If
End If
End If
End Sub
Sub TopicAdminOptions()
If Cat_Status = 0 Then
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Category&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconUnlock,"Un-Lock Category","hspace=""0""") & "</a>" & vbNewLine
ElseIf Forum_Status = 0 Then
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Forum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconUnlock,"Un-Lock Forum","hspace=""0""") & "</a>" & vbNewLine
ElseIf Topic_Status <> 0 Then
Response.Write " <a href=""JavaScript:openWindow('pop_lock.asp?mode=Topic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconLock,"Lock Topic","hspace=""0""") & "</a>" & vbNewLine
Else
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Topic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconUnlock,"Un-Lock Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If (ModerateAllowed = "Y") or (Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0) Then
' ## Poll Below
Response.Write " <a href=""post.asp?" & pollLink & "method=EditTopic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&auth=" & Topic_Author & """>" & getCurrentIcon(strIconPencil,"Edit Topic","hspace=""0""") & "</a>" & vbNewLine
End If
Response.Write " <a href=""JavaScript:openWindow('pop_delete.asp?" & pollLink & "mode=Topic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconTrashcan,"Delete Topic","hspace=""0""") & "</a>" & vbNewLine
' ## Poll Above
If Topic_Status <= 1 Then
Response.Write " <a href=""post.asp?method=Reply&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconReplyTopic,"Reply to Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If Topic_Status > 1 Then
TopicString = "TOPIC_ID=" & Topic_ID & "&CAT_ID=" & Cat_ID & "&FORUM_ID=" & Forum_ID
Response.Write " <a href=""JavaScript:openWindow('pop_moderate.asp?" & TopicString & "')"">" & getCurrentIcon(strIconFolderModerate,"Approve/Hold/Reject this Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If (strSubscription < 4 and strSubscription > 0) and (CatSubscription > 0) and ForumSubscription > 0 and strEmail = 1 Then
If InArray(strTopicSubs, Topic_ID) Then
Response.Write " " & ShowSubLink ("U", Cat_ID, Forum_ID, Topic_ID, "N")
ElseIf strBoardSubs <> "Y" and not(InArray(strForumSubs,Forum_ID) or InArray(strCatSubs,Cat_ID)) Then
Response.Write " " & ShowSubLink ("S", Cat_ID, Forum_ID, Topic_ID, "N")
End If
End If
End Sub
Sub TopicMemberOptions()
If (Topic_Status > 0 and Topic_Author = MemberID) or (ModerateAllowed = "Y") Then
' ## Poll Below
Response.Write " <a href=""post.asp?" & pollLink & "method=EditTopic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconPencil,"Edit Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If (Topic_Status > 0 and Topic_Author = MemberID and Topic_Replies = 0) or (ModerateAllowed = "Y") Then
Response.Write " <a href=""JavaScript:openWindow('pop_delete.asp?" & pollLink & "mode=Topic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconTrashcan,"Delete Topic","hspace=""0""") & "</a>" & vbNewLine
' ## Poll Above
End If
If Topic_Status <= 1 Then
Response.Write " <a href=""post.asp?method=Reply&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconReplyTopic,"Reply to Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If (strSubscription < 4 and strSubscription > 0) and (CatSubscription > 0) and ForumSubscription > 0 and strEmail = 1 Then
If InArray(strTopicSubs, Topic_ID) Then
Response.Write " " & ShowSubLink ("U", Cat_ID, Forum_ID, Topic_ID, "N")
ElseIf strBoardSubs <> "Y" and not(InArray(strForumSubs,Forum_ID) or InArray(strCatSubs,Cat_ID)) Then
Response.Write " " & ShowSubLink ("S", Cat_ID, Forum_ID, Topic_ID, "N")
End If
End If
End Sub
Sub TopicPaging()
mxpages = (Topic_Replies / strPageSize)
If mxPages <> cLng(mxPages) Then
mxpages = int(mxpages) + 1
End If
If mxpages > 1 Then
Response.Write " <table border=""0"" cellspacing=""0"" cellpadding=""0"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td valign=""bottom""><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>" & getCurrentIcon(strIconPosticon,"","align=""absmiddle""") & "</font></td>" & vbNewLine
For counter = 1 to mxpages
ref = " <td align=""right"" valign=""bottom"" bgcolor=""" & strForumCellColor & """><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>"
If ((mxpages > 9) and (mxpages > strPageNumberSize)) or ((counter > 9) and (mxpages < strPageNumberSize)) Then
ref = ref & " "
End If
ref = ref & widenum(counter) & "<span class=""spnMessageText""><a href=""topic.asp?"
ref = ref & ArchiveLink
ref = ref & "TOPIC_ID=" & Topic_ID
ref = ref & "&whichpage=" & counter
ref = ref & """>" & counter & "</a></span></font></td>"
Response.Write ref & vbNewLine
If counter mod strPageNumberSize = 0 and counter < mxpages Then
Response.Write " </tr>" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td> </td>" & vbNewLine
End If
Next
Response.Write " </tr>" & vbNewLine & _
" </table>" & vbNewLine
End If
End Sub
Function DoLastPostLink()
If Topic_Replies < 1 or Topic_Last_Post_Reply_ID = 0 Then
DoLastPostLink = "<a href=""topic.asp?" & ArchiveLink & "TOPIC_ID=" & Topic_ID & """>" & getCurrentIcon(strIconLastpost,"Jump to Last Post","align=""absmiddle""") & "</a>"
ElseIf Topic_Last_Post_Reply_ID <> 0 Then
PageLink = "whichpage=-1&"
AnchorLink = "&REPLY_ID="
DoLastPostLink = "<a href=""topic.asp?" & ArchiveLink & PageLink & "TOPIC_ID=" & Topic_ID & AnchorLink & Topic_Last_Post_Reply_ID & """>" & getCurrentIcon(strIconLastpost,"Jump to Last Post","align=""absmiddle""") & "</a>"
Else
DoLastPostLink = ""
End If
End Function
function aGetColspan(lIN, lOUT)
If (mlev > 0 or strNoCookies = "1") Then
lOut = lOut + 1
End If
If lOut > lIn Then
aGetColspan = lIN
Else
aGetColspan = lOUT
End If
End Function
Sub DoHideCategory(intCatId)
HideForumCat = strUniqueID & "HideCat" & intCatId
If Request.QueryString(HideForumCat) = "Y" Then
Response.Cookies(HideForumCat) = "Y"
Response.Cookies(HideForumCat).Expires = dateAdd("d", 30, strForumTimeAdjust)
Else
If Request.QueryString(HideForumCat) = "N" Then
Response.Cookies(HideForumCat) = "N"
Response.Cookies(HideForumCat).Expires = dateadd("d", -2, strForumTimeAdjust)
End If
End If
End sub
%>
|
MaGraham |
Posted - 17 December 2013 : 12:08:37 You guys are much too kind. . .and I LOVE IT! [giggle]
I LOVE being creative, especially with graphics and such but I never could have accomplished any of this without all of you guys. . .especially our dear Carefree! He is such a perfectionist and it definitely shows in his incredible work!!
But such a blessing all of you are!
I REALLY do appreciate you guys!! [hugs]
|
AnonJr |
Posted - 17 December 2013 : 10:13:47 quote: Originally posted by Davio
Very very nice MaGraham! Very well done on what you have accomplished so far. Haven't seen so much effort go into customizing the forum in a long while. If we had our Snitz Forums Award still up, would definitely give you a prize.
Well done.
I'll second that. |
Davio |
Posted - 16 December 2013 : 20:22:10 Very very nice MaGraham! Very well done on what you have accomplished so far. Haven't seen so much effort go into customizing the forum in a long while. If we had our Snitz Forums Award still up, would definitely give you a prize.
Well done. |
MaGraham |
Posted - 16 December 2013 : 17:19:30 I believe it was Davio who said he wanted to see what my active.asp looked like after all of the changes I made so I thought I'd post a screen shot of just a couple of my forums along with the menu at the top. Members were saying they found it difficult to find things with the small menu in the top-right of the Snitz default menu, so that's the reason I wanted to do a different menu and thought I'd share it in the screen shot, too.
I PhotoShopped this screen shot below, obviously. Members LOVE being able to see the profile picture of the "Author" and "Last Poster" of each topic. These display on the forums as well. The "Author" column obviously has the member's name under their avatar so I wanted members to be able to do a mouseover on the "Last Poster" in case they don't know a member in that column. I placed that ability in the screen shot below, too.
And just so you'll know, my forums are private so I have removed all identifiable info from the screen shot. None of the names you see are actually names of my members. And, I have blurred the faces as well.
Forgive me for leaving these images full size. If someone would like to resize them, please feel free. I just thought someone might need the full size to see all of the details.
I really like having the birthdays at the bottom on the active.asp, too. Thank you, Carefree, for your help with that!
As you can see from the graphic above, I have the default setting for my active.asp set to reload every ten minutes. Members LOVE it but obviously have the optioin of changing that! Facebook doesn't offer that option! It's also Soo neat to have the option to go back for up to two whole months to find something you're looking for or to see things you've missed with just one click! Facebook doesn't offer that option either!
As I've mentioned before in a post somewhere on here, I used Marcel's "Weblog" mod I found here and, with Carefree's help, I created something I call "Status Updates" for members to easily share what's going on in their life or what they're doing "today," etc. somewhat like many do on Facebook. I like this better than Facebook! Members have the option to "Click to see Who Commented" sort of like on Facebook but unlike Facebook, they don't have to scroll through EVERYONE'S comments; they only see a link to the different topics and status updates and can, obviously, choose not to click on the link. And also unlike Facebook. . .by clicking on the "Click to see Who Commented," members can see how MANY times someone has commented. Having to scroll through SO MANY comments on Facebook is such a pain! (And also even better than Facebook, members can EDIT their status updates on my site!)
When members click on the link to see who has commented, this is a screen shot example below of what they see. And as you can see, in the column on the right, members can see how many times each member has commented. It, too, has the mouseover effect for the member's avatars.
In the top-right in the "Contact" area of my menu in the first screen shot you'll see a few other things I felt the forums needed. I especially wanted a means for the members to delete their account. I used Carefree's "Bug Reporter" mod here and created an "Account Deletion" mod. With that, a member can click on the link in the menu and get a deletion form that, when submitted, comes straight to my PM inbox. And whether or not I'm on my site, I have my private message notifications set to send me an email when I receive a PM.
When completing an "Account Deletion" form, I require members to provide a valid email address for me to use instead of replying to them by PM. . .because if they're really wanting to leave the site they are more than likely upset and won't be back to even see a PM. And, as we all know, all members don't update their email address in their profile.
I explain in the email I will send to members, after receiving their "Account Deletion" PM notice, if they don't reply to my email no action will be taken. I require that they send a confirmation email reply confirming they do indeed wish to delete their account. I also explain that their account will be deleted in 14 days after I receive their confirmation email. I feel that the average person will most likely change their mind within 14 days if their reason is just that they are upset. I've only had one member to want to delete her account and she did change her mind within the 14 days.
This is a screen shot of the "Account Deletion Form" a member would get after clicking on the "Delete My Account" link in my menu.
So as you see below, I've used Carefree's "Bug Reporter" mod here over and over in ways like this below and I place a link to each in the menu. It sure makes things very easy for me and for the members. The only easier thing would be to place a link in the posts next to the other icons for these. Hint, hint.
"Report a Member" mod:
"Report a Website Problem" mod:
Carefree's "Bug Reporter" here is so easy to redo and use in ways I mentioned above. Obviously, I color-coordinated each of them to match my site colors. I'm sure some of you could come up with the coding to do an automatic reply to things such as the "Account Deletion" email that's needed after the PM is received. Hint, hint.
I also redid all of my icons, too. Obviously, the "folder" icons of Snitz were just so outdated. My red "hot topic" icon is animated and so is my green "new post" icon.
|
MaGraham |
Posted - 16 December 2013 : 13:36:40 quote: Originally posted by HuwR
could you post a text copy of your active.asp so that I can ensure it works with your version when I do.
cheers.
Ohhh, I am Sooo excited!
<%
'###############################################################################
'##
'## Snitz Forums 2000 v3.4.07
'##
'###############################################################################
'##
'## Copyright © 2000-09 Michael Anderson, Pierre Gorissen,
'## Huw Reddick and Richard Kinser
'##
'## This program is free. You can redistribute and/or modify it under the
'## terms of the GNU General Public License as published by the Free Software
'## Foundation; either version 2 or (at your option) any later version.
'##
'## All copyright notices regarding Snitz Forums 2000 must remain intact in
'## the scripts and in the HTML output. The "powered by" text/logo with a
'## link back to http://forum.snitz.com in the footer of the pages MUST
'## remain visible when the pages are viewed on the internet or intranet.
'##
'## This program is distributed in the hope that it will be useful but
'## WITHOUT ANY WARRANTY; without even an 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:
'##
'## Free Software Foundation, Inc.
'## 59 Temple Place, Suite 330
'## Boston, MA 02111-1307
'##
'## Support can be obtained from our support forums at:
'##
'## http://forum.snitz.com
'##
'## Correspondence and marketing questions can be sent to:
'##
'## manderson@snitz.com
'##
'###############################################################################
%>
<!--#INCLUDE FILE="config.asp"-->
<%
nRefreshTime = Request.Cookies(strCookieURL & "Reload")
If Request.Form("cookie") = "1" Then
If strSetCookieToForum = 1 Then
Response.Cookies(strCookieURL & "Reload").Path = strCookieURL
End If
Response.Cookies(strCookieURL & "Reload") = Request.Form("RefreshTime")
Response.Cookies(strCookieURL & "Reload").Expires = strForumTimeAdjust + 365
nRefreshTime = Request.Form("RefreshTime")
End If
If nRefreshTime = "" Then
nRefreshTime = 10
End If
ActiveSince = Request.Cookies(strCookieURL & "ActiveSince")
If Request.Form("cookie") = "2" Then
ActiveSince = Request.Form("ShowSinceDateTime")
If strSetCookieToForum = 1 Then
Response.Cookies(strCookieURL & "ActiveSince").Path = strCookieURL
End If
Response.Cookies(strCookieURL & "ActiveSince") = ActiveSince
End If
Dim ModerateAllowed
Dim HasHigherSub
Dim HeldFound, UnApprovedFound, UnModeratedPosts, UnModeratedFPosts
Dim canView
HasHigherSub = false
%>
<!--#INCLUDE FILE="inc_sha256.asp" -->
<!--#INCLUDE FILE="inc_header.asp" -->
<!--#INCLUDE FILE="inc_func_secure.asp" -->
<!--#INCLUDE FILE="inc_moderation.asp" -->
<!--#INCLUDE FILE="inc_subscription.asp" -->
<!--#INCLUDE FILE="inc_birthdays.asp" -->
<%
Select Case ActiveSince
Case "LastVisit"
lastDate = ""
Case "LastFifteen"
lastDate = DateToStr(DateAdd("n",-15,strForumTimeAdjust))
Case "LastThirty"
lastDate = DateToStr(DateAdd("n",-30,strForumTimeAdjust))
Case "LastFortyFive"
lastDate = DateToStr(DateAdd("n",-45,strForumTimeAdjust))
Case "LastHour"
lastDate = DateToStr(DateAdd("h",-1,strForumTimeAdjust))
Case "Last2Hours"
lastDate = DateToStr(DateAdd("h",-2,strForumTimeAdjust))
Case "Last6Hours"
lastDate = DateToStr(DateAdd("h",-6,strForumTimeAdjust))
Case "Last12Hours"
lastDate = DateToStr(DateAdd("h",-12,strForumTimeAdjust))
Case "LastDay"
lastDate = DateToStr(DateAdd("d",-1,strForumTimeAdjust))
Case "Last2Days"
lastDate = DateToStr(DateAdd("d",-2,strForumTimeAdjust))
Case "LastWeek"
lastDate = DateToStr(DateAdd("ww",-1,strForumTimeAdjust))
Case "Last2Weeks"
lastDate = DateToStr(DateAdd("ww",-2,strForumTimeAdjust))
Case "LastMonth"
lastDate = DateToStr(DateAdd("m",-1,strForumTimeAdjust))
Case "Last2Months"
lastDate = DateToStr(DateAdd("m",-2,strForumTimeAdjust))
Case Else
lastDate = ""
End Select
Response.Write " <script language=""JavaScript"" type=""text/javascript"">" & vbNewLine & _
" <!--" & vbNewLine & _
" function autoReload() { document.ReloadFrm.submit() }" & vbNewLine & _
" function SetLastDate() { document.LastDateFrm.submit() }" & vbNewLine & _
" function jumpTo(s) { if (s.selectedIndex != 0) location.href = s.options[s.selectedIndex].value;return 1;}" & vbNewLine & _
" //defaultStatus = ""You last loaded this page on " & chkDate(DateToStr(strForumTimeAdjust)," ",true) & " (Forum Time)""" & vbNewLine & _
" // -->" & vbNewLine & _
" </script>" & vbNewLine
If IsEmpty(Session(strCookieURL & "last_here_date")) Then
Session(strCookieURL & "last_here_date") = ReadLastHereDate(strDBNTUserName)
End If
If lastDate = "" Then
lastDate = Session(strCookieURL & "last_here_date")
End If
If Request.Form("AllRead") = "Y" Then
lastDate = ChkString(Request.Form("BuildTime"),"SQLString")
'## The redundant line below is necessary, don't delete it.
Session(strCookieURL & "last_here_date") = lastDate
Session(strCookieURL & "last_here_date") = lastDate
UpdateLastHereDate lastDate,strDBNTUserName
ActiveSince = ""
End If
If strModeration = "1" and mLev > 2 Then
UnModeratedPosts = CheckForUnmoderatedPosts("BOARD", 0, 0, 0)
End If
Dim strSubString, strSubArray, strBoardSubs, strCatSubs, strForumSubs, strTopicSubs
If MySubCount > 0 Then
strSubString = PullSubscriptions(0,0,0)
strSubArray = Split(strSubString,";")
If uBound(strSubArray) < 0 Then
strBoardSubs = ""
strCatSubs = ""
strForumSubs = ""
strTopicSubs = ""
Else
strBoardSubs = strSubArray(0)
strCatSubs = strSubArray(1)
strForumSubs = strSubArray(2)
strTopicSubs = strSubArray(3)
End If
End If
If mlev = 3 Then
strSql = "SELECT FORUM_ID FROM " & strTablePrefix & "MODERATOR " & _
" WHERE MEMBER_ID = " & MemberID
Set rsMod = Server.CreateObject("ADODB.Recordset")
rsMod.Open strSql, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText
If rsMod.EOF Then
recModCount = ""
Else
allModData = rsMod.GetRows(adGetRowsRest)
recModCount = UBound(allModData,2)
End If
RsMod.Close
Set RsMod = Nothing
If recModCount <> "" Then
For x = 0 to recModCount
If x = 0 Then
ModOfForums = allModData(0,x)
Else
ModOfForums = ModOfForums & "," & allModData(0,x)
End If
Next
Else
ModOfForums = ""
End If
Else
ModOfForums = ""
End If
If strPrivateForums = "1" and mLev < 4 Then
allAllowedForums = ""
allowSql = "SELECT FORUM_ID, F_SUBJECT, F_PRIVATEFORUMS, F_PASSWORD_NEW"
allowSql = allowSql & " FROM " & strTablePrefix & "FORUM"
allowSql = allowSql & " WHERE F_TYPE = 0"
allowSql = allowSql & " ORDER BY FORUM_ID"
Set rsAllowed = Server.CreateObject("ADODB.Recordset")
rsAllowed.Open allowSql, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText
If rsAllowed.EOF Then
recAllowedCount = ""
Else
allAllowedData = rsAllowed.GetRows(adGetRowsRest)
recAllowedCount = UBound(allAllowedData,2)
End If
rsAllowed.Close
Set rsAllowed = Nothing
If recAllowedCount <> "" Then
fFORUM_ID = 0
fF_SUBJECT = 1
fF_PRIVATEFORUMS = 2
fF_PASSWORD_NEW = 3
For RowCount = 0 to recAllowedCount
Forum_ID = allAllowedData(fFORUM_ID,RowCount)
Forum_Subject = allAllowedData(fF_SUBJECT,RowCount)
Forum_PrivateForums = allAllowedData(fF_PRIVATEFORUMS,RowCount)
Forum_FPasswordNew = allAllowedData(fF_PASSWORD_NEW,RowCount)
If mLev = 4 Then
ModerateAllowed = "Y"
ElseIf mLev = 3 and ModOfForums <> "" Then
If (strAuthType = "nt") Then
If (chkForumModerator(Forum_ID, Session(strCookieURL & "username")) = "1") Then ModerateAllowed = "Y" Else ModerateAllowed = "N"
Else
If (instr("," & ModOfForums & "," ,"," & Forum_ID & ",") > 0) Then ModerateAllowed = "Y" Else ModerateAllowed = "N"
End If
Else
ModerateAllowed = "N"
End If
If chkForumAccessNew(Forum_PrivateForums,Forum_FPasswordNew,Forum_Subject,Forum_ID,MemberID) = true Then
If allAllowedForums = "" Then
allAllowedForums = Forum_ID
Else
allAllowedForums = allAllowedForums & "," & Forum_ID
End If
End If
Next
End If
If allAllowedForums = "" Then allAllowedForums = 0
End If
' ## Msg Icon & Poll Below
strSql = "SELECT F.FORUM_ID, " & _
"F.F_SUBJECT, " & _
"F.F_SUBSCRIPTION, " & _
"F.F_STATUS, " & _
"C.CAT_ID, " & _
"C.CAT_NAME, " & _
"C.CAT_SUBSCRIPTION, " & _
"C.CAT_STATUS, " & _
"T.T_STATUS, " & _
"T.T_VIEW_COUNT, " & _
"T.TOPIC_ID, " & _
"T.T_ISPOLL, " &_
"T.T_SUBJECT, " & _
"T.T_AUTHOR, " & _
"T.T_REPLIES, " & _
"T.T_UREPLIES, " & _
"M.M_NAME, " & _
"T.T_LAST_POST_AUTHOR, " & _
"T.T_LAST_POST, " & _
"T.T_LAST_POST_REPLY_ID, " & _
"MEMBERS_1.M_NAME AS LAST_POST_AUTHOR_NAME, " & _
"T.T_MSGICON, " & _
"F.F_PRIVATEFORUMS, " & _
"F.F_PASSWORD_NEW, " & _
"M.M_AVATAR_URL " & _
"FROM " & strMemberTablePrefix & "MEMBERS M, " & _
strTablePrefix & "FORUM F, " & _
strTablePrefix & "TOPICS T, " & _
strTablePrefix & "CATEGORY C, " & _
strMemberTablePrefix & "MEMBERS MEMBERS_1 " & _
"WHERE T.T_LAST_POST_AUTHOR = MEMBERS_1.MEMBER_ID "
' ## Msg Icon & Poll Above
If strPrivateForums = "1" and mLev < 4 Then
strSql = strSql & " AND F.FORUM_ID IN (" & allAllowedForums & ") "
End If
'####### Begin UserGroup MOD #######
strDeniedForums = Session(strCookieURL & "DeniedForums" & MemberID)
if strDeniedForums <> "" and strDeniedForums <> "-1" then
strSql = strSql & " AND F.FORUM_ID NOT IN(" & Session(strCookieURL & "DeniedForums" & MemberID) & ") "
end if
'####### End UserGroup MOD #######
strSql = strSql & "AND F.F_TYPE = 0 " & _
"AND F.FORUM_ID = T.FORUM_ID " & _
"AND C.CAT_ID = T.CAT_ID " & _
"AND M.MEMBER_ID = T.T_AUTHOR " & _
"AND (T.T_LAST_POST > '" & lastDate & "'"
If mlev <> 4 Then
strSql = strSql & " AND ((T.T_AUTHOR <> " & MemberID &_
" AND T.T_STATUS < 2)" ' Ignore unapproved/held posts
If mlev = 3 and ModOfForums <> "" Then
strSql = strSql & " OR T.FORUM_ID IN (" & ModOfForums & ") "
End If
strSql = strSql & " OR T.T_AUTHOR = " & MemberID & ")"
End If
If Group > 1 and strGroupCategories = "1" Then
strSql = strSql & " AND (C.CAT_ID = 0"
If recGroupCatCount <> "" Then
For iGroupCat = 0 to recGroupCatCount
strSql = strSql & " or C.CAT_ID = " & allGroupCatData(1, iGroupCat)
Next
strSql = strSql & ")"
Else
strSql = strSql & ")"
End If
End If
strSql = strSql & ") "
strSql = strSql & " ORDER BY C.CAT_ORDER, C.CAT_NAME, F.F_ORDER, F.F_SUBJECT, T.T_LAST_POST DESC "
Set rs = Server.CreateObject("ADODB.Recordset")
If strDBType <> "mysql" Then rs.cachesize = 50
rs.Open strSql, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText
If rs.EOF Then
recActiveTopicsCount = ""
Else
allActiveTopics = rs.GetRows(adGetRowsRest)
recActiveTopicsCount = UBound(allActiveTopics,2)
rs.Close
End If
Set rs = Nothing
' ## Events Calendar Below
strSQL = "SELECT T.TOPIC_ID FROM " & strTablePrefix & "TOPICS AS T INNER JOIN " & strTablePrefix & "CAL_EVENTS AS C ON T.TOPIC_ID = C.TOPIC_ID WHERE T.T_LAST_POST > '" & lastDate & "' GROUP BY T.TOPIC_ID"
Set rsCal = Server.CreateObject("ADODB.Recordset")
rsCal.Open StrSql, My_conn
If not rsCal.EOF Then
arrTopicID = rsCal.GetRows
rsCal.Close
Else
blnCalNoEvents = TRUE
End If
Set rsCal = Nothing
' ## Events Calendar Above
Response.Write " <table width=""100%"" border=""0"" cellspacing=""0"" cellpadding=""0"" align=""center"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <form name=""LastDateFrm"" action=""active.asp"" method=""post""><td>" & vbNewLine & _
" <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine & _
" " & getCurrentIcon(strIconFolderOpen,"","") & " <a href=""default.asp"">COMMUNITY HOME</a><br />" & vbNewLine & _
" " & getCurrentIcon(strIconBar,"","") & getCurrentIcon(strIconFolderOpenTopic,"","") & " " & _
"Active Topics Since " & vbNewLine
Response.Write " <select name=""ShowSinceDateTime"" size=""1"" onchange=""SetLastDate();"">" & vbNewLine & _
" <option value=""LastVisit"""
If ActiveSince = "LastVisit" or ActiveSince = "" Then
Response.Write " selected"
End If
Response.Write "> Last Visit on " & ChkDate(Session(strCookieURL & "last_here_date"),"",true) & " </option>" & vbNewLine & _
" <option value=""LastFifteen""" & chkSelect(ActiveSince,"LastFifteen") & "> Last 15 minutes</option>" & vbNewLine & _
" <option value=""LastThirty""" & chkSelect(ActiveSince,"LastThirty") & "> Last 30 minutes</option>" & vbNewLine & _
" <option value=""LastFortyFive""" & chkSelect(ActiveSince,"LastFortyFive") & "> Last 45 minutes</option>" & vbNewLine & _
" <option value=""LastHour""" & chkSelect(ActiveSince,"LastHour") & "> Last Hour</option>" & vbNewLine & _
" <option value=""Last2Hours""" & chkSelect(ActiveSince,"Last2Hours") & "> Last 2 Hours</option>" & vbNewLine & _
" <option value=""Last6Hours""" & chkSelect(ActiveSince,"Last6Hours") & "> Last 6 Hours</option>" & vbNewLine & _
" <option value=""Last12Hours""" & chkSelect(ActiveSince,"Last12Hours") & "> Last 12 Hours</option>" & vbNewLine & _
" <option value=""LastDay""" & chkSelect(ActiveSince,"LastDay") & "> Yesterday</option>" & vbNewLine & _
" <option value=""Last2Days""" & chkSelect(ActiveSince,"Last2Days") & "> Last 2 Days</option>" & vbNewLine & _
" <option value=""LastWeek""" & chkSelect(ActiveSince,"LastWeek") & "> Last Week</option>" & vbNewLine & _
" <option value=""Last2Weeks""" & chkSelect(ActiveSince,"Last2Weeks") & "> Last 2 Weeks</option>" & vbNewLine & _
" <option value=""LastMonth""" & chkSelect(ActiveSince,"LastMonth") & "> Last Month</option>" & vbNewLine & _
" <option value=""Last2Months""" & chkSelect(ActiveSince,"Last2Months") & "> Last 2 Months</option>" & vbNewLine & _
" </select>" & vbNewLine & _
" <input type=""hidden"" name=""Cookie"" value=""2"">" & vbNewLine & _
" </font>" & vbNewLine & _
" </td>" & vbNewLine & _
" </form>" & vbNewLine & _
" <td align=""center""> </td>" & vbNewLine & _
" <form name=""ReloadFrm"" action=""active.asp"" method=""post"">" & vbNewLine & _
" <td align=""right"">" & vbNewLine & _
" <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & _
" <br />" & vbNewLine & _
" <select name=""RefreshTime"" size=""1"" onchange=""autoReload();"">" & vbNewLine & _
" <option value=""0""" & chkSelect(nRefreshTime,0) & ">Don't reload automatically</option>" & vbNewLine & _
" <option value=""1""" & chkSelect(nRefreshTime,1) & ">Reload page every minute</option>" & vbNewLine & _
" <option value=""2""" & chkSelect(nRefreshTime,2) & ">Reload page every 2 minutes</option>" & vbNewLine & _
" <option value=""5""" & chkSelect(nRefreshTime,5) & ">Reload page every 5 minutes</option>" & vbNewLine & _
" <option value=""10""" & chkSelect(nRefreshTime,10) & ">Reload page every 10 minutes</option>" & vbNewLine & _
" <option value=""15""" & chkSelect(nRefreshTime,15) & ">Reload page every 15 minutes</option>" & vbNewLine & _
" </select>" & vbNewLine & _
" <input type=""hidden"" name=""Cookie"" value=""1"">" & vbNewLine & _
" </font>" & vbNewLine & _
" </td>" & vbNewLine & _
" </form>" & vbNewLine & _
" </tr>" & vbNewLine & _
" </table>" & vbNewLine & _
" <font size=""" & strFooterFontSize & """><br /></font>" & vbNewLine & _
" <table border=""0"" width=""100%"" cellspacing=""0"" cellpadding=""0"" align=""center"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td bgcolor=""" & strTableBorderColor & """>" & vbNewLine & _
" <table border=""0"" width=""100%"" cellspacing=""1"" cellpadding=""4"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """ valign=""middle""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>" & vbNewLine
If recActiveTopicsCount <> "" and (mLev > 0) Then
Response.Write " <form name=""MarkRead"" action=""active.asp"" method=""post"" style=""display:inline"">" & vbNewLine & _
" <input type=""hidden"" name=""AllRead"" value=""Y"">" & vbNewLine & _
" <input type=""hidden"" name=""BuildTime"" value=""" & DateToStr(strForumTimeAdjust) & """>" & vbNewLine & _
" <input type=""hidden"" name=""Cookie"" value=""2"">" & vbNewLine & _
" <acronym style=""border:none; text-decoration:none"" title=""Mark all topics as read""><input type=""image"" src=""" & strImageUrl & "icon_topic_all_read.png"" value=""Mark all read"" id=""submit1"" name=""Mark all topics as read"" border=""0""" & dWStatus("Mark all topics as read") & "></acronym></font></td>" & vbNewLine & _
" </form>" & vbNewLine
Else
Response.Write " </font></td>" & vbNewLine
End If
Response.Write " <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """> </font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Topic</font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Author</font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Comments</font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Read</font></b></td>" & vbNewLine & _
" <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Last Poster</font></b></td>" & vbNewLine
If (mlev > 0) or (lcase(strNoCookies) = "1") Then
Response.Write " <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>"
If (mLev = 4 or mLev = 3) or (lcase(strNoCookies) = "1") Then
If UnModeratedPosts > 0 Then
UnModeratedFPosts = 0
Response.Write "<a href=""moderate.asp"">" & getCurrentIcon(strIconFolderModerate,"View All UnModerated Posts","hspace=""0""") & "</a>"
Else
Response.Write(" ")
End If
Else
Response.Write(" ")
End If
Response.Write "</font></b></td>" & vbNewLine
End If
Response.Write " </tr>" & vbNewLine
If recActiveTopicsCount = "" Then
Response.Write " <tr>" & vbNewLine & _
" <td colspan=""8"" bgcolor=""" & strForumCellColor & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """><b>No Active Topics Found</b></font></td>" & vbNewLine & _
" </tr>" & vbNewLine
Else
currForum = 0
fDisplayCount = 0
canAccess = 0
fFORUM_ID = 0
fF_SUBJECT = 1
fF_SUBSCRIPTION = 2
fF_STATUS = 3
fCAT_ID = 4
fCAT_NAME = 5
fCAT_SUBSCRIPTION = 6
fCAT_STATUS = 7
fT_STATUS = 8
fT_VIEW_COUNT = 9
fTOPIC_ID = 10
' ## Poll Below
fIS_POLL = 11
' ## Poll Above
fT_SUBJECT = 12
fT_AUTHOR = 13
fT_REPLIES = 14
fT_UREPLIES = 15
fM_NAME = 16
fT_LAST_POST_AUTHOR = 17
fT_LAST_POST = 18
fT_LAST_POST_REPLY_ID = 19
fLAST_POST_AUTHOR_NAME = 20
fT_MSGICON = 21
fF_PRIVATEFORUMS = 22
fF_PASSWORD_NEW = 23
fM_AVATAR_URL = 24
For RowCount = 0 to recActiveTopicsCount
'## Store all the recordvalues in variables first.
Forum_ID = allActiveTopics(fFORUM_ID,RowCount)
Forum_Subject = allActiveTopics(fF_SUBJECT,RowCount)
ForumSubscription = allActiveTopics(fF_SUBSCRIPTION,RowCount)
Forum_Status = allActiveTopics(fF_STATUS,RowCount)
Cat_ID = allActiveTopics(fCAT_ID,RowCount)
Cat_Name = allActiveTopics(fCAT_NAME,RowCount)
CatSubscription = allActiveTopics(fCAT_SUBSCRIPTION,RowCount)
Cat_Status = allActiveTopics(fCAT_STATUS,RowCount)
Topic_Status = allActiveTopics(fT_STATUS,RowCount)
Topic_View_Count = allActiveTopics(fT_VIEW_COUNT,RowCount)
Topic_ID = allActiveTopics(fTOPIC_ID,RowCount)
Topic_Subject = allActiveTopics(fT_SUBJECT,RowCount)
Topic_Author = allActiveTopics(fT_AUTHOR,RowCount)
Topic_Replies = allActiveTopics(fT_REPLIES,RowCount)
Topic_UReplies = allActiveTopics(fT_UREPLIES,RowCount)
Member_Name = allActiveTopics(fM_NAME,RowCount)
Topic_Last_Post_Author = allActiveTopics(fT_LAST_POST_AUTHOR,RowCount)
Topic_Last_Post = allActiveTopics(fT_LAST_POST,RowCount)
Topic_Last_Post_Reply_ID = allActiveTopics(fT_LAST_POST_REPLY_ID,RowCount)
Topic_Last_Post_Author_Name = chkString(allActiveTopics(fLAST_POST_AUTHOR_NAME,RowCount),"display")
Topic_MsgIcon = allActiveTopics(fT_MSGICON,RowCount)
Forum_PrivateForums = allActiveTopics(fF_PRIVATEFORUMS,RowCount)
Forum_FPasswordNew = allActiveTopics(fF_PASSWORD_NEW,RowCount)
Member_Avatar = allActiveTopics(fM_AVATAR_URL,RowCount)
strSqlAv = "SELECT M_AVATAR_URL FROM " & strMemberTablePrefix & "MEMBERS WHERE MEMBER_ID = " & Topic_Last_Post_Author
Set rsLPost=my_Conn.Execute(strSqlAv)
If not rsLPost.EOF Then
strLPostAvatar=rsLPost("M_AVATAR_URL")
rsLPost.Close
End If
Set rsLPost=Nothing
' ## Events Calendar Below
blnEvent = False
If not blnCalNoEvents Then
For each ttID in arrTopicID
If cLng(ttID) = cLng(TOPIC_ID) Then
blnEvent = TRUE
Exit For
End If
Next
End If
' ## Events Calendar Above
' ## Poll Below
IsPoll = allActiveTopics(fIS_POLL,RowCount)
If IsPoll = 1 Then
pollLink = "poll=1&"
Else
pollLink = ""
End If
' ## Poll Above
If mLev = 4 Then
ModerateAllowed = "Y"
ElseIf mLev = 3 and ModOfForums <> "" Then
If (strAuthType = "nt") Then
If (chkForumModerator(Forum_ID, Session(strCookieURL & "username")) = "1") Then ModerateAllowed = "Y" Else ModerateAllowed = "N"
Else
If (instr("," & ModOfForums & "," ,"," & Forum_ID & ",") > 0) Then ModerateAllowed = "Y" Else ModerateAllowed = "N"
End If
Else
ModerateAllowed = "N"
End If
If ModerateAllowed = "Y" and Topic_UReplies > 0 Then
Topic_Replies = Topic_Replies + Topic_UReplies
End If
fDisplayCount = fDisplayCount + 1
If currForum <> Forum_ID Then
Response.Write " <tr>" & vbNewLine & _
" <td height=""20"" colspan=""7"" bgcolor=""" & strCategoryCellColor & """ valign=""middle""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strCategoryFontColor & """><a href=""default.asp?CAT_ID=" & Cat_ID & """><font color=""" & strCategoryFontColor & """><b>" & ChkString(Cat_Name,"display") & "</b></font></a> / <a href=""forum.asp?FORUM_ID=" & Forum_ID & """><font color=""" & strCategoryFontColor & """><b>" & ChkString(Forum_Subject,"display") & "</b></font></a></font></td>" & vbNewLine
If (mlev > 0) or (lcase(strNoCookies) = "1") Then
Response.Write " <td align=""center"" bgcolor=""" & strCategoryCellColor & """ nowrap valign=""middle"">" & vbNewLine
If (ModerateAllowed = "Y") or (lcase(strNoCookies) = "1") Then
ForumAdminOptions
Else
If Cat_Status <> 0 and Forum_Status <> 0 Then
ForumMemberOptions
Else
Response.Write " " & vbNewLine
End If
End If
Response.Write " </td>" & vbNewLine
ElseIf (mLev = 3) Then
Response.Write " <td align=""center"" bgcolor=""" & strCategoryCellColor & """ nowrap valign=""middle""> </td>" & vbNewLine
End If
Response.Write " </tr>" & vbNewLine
End If
Response.Write " <tr>" & vbNewLine
Response.Write " <td bgcolor=""" & strForumCellColor & """ align=""center"" valign=""middle"">"
Response.Write "<a href=""topic.asp?TOPIC_ID=" & Topic_ID & """>"
If Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0 Then
If Topic_Status = 2 Then
UnApprovedFound = "Y"
Response.Write getCurrentIcon(strIconFolderUnmoderated,"Topic Not Moderated","hspace=""0""") & "</a>" & vbNewLine
ElseIf Topic_Status = 3 Then
HeldFound = "Y"
Response.Write getCurrentIcon(strIconFolderHold,"Topic on Hold","hspace=""0""") & "</a>" & vbNewLine
' DEM --> end of code Added For topic moderation
' ## Events Calendar Below
ElseIf blnEvent Then
Response.Write getCurrentIcon(strCalIconEvent, strCalEvent,"")
' ## Events Calendar Above
ElseIf lcase(strHotTopic) = "1" and Topic_Replies >= intHotTopicNum Then
Response.Write getCurrentIcon(strIconFolderNewHot,"Hot Topic with New Posts","hspace=""0""") & "</a>" & vbNewLine
ElseIf Topic_Last_Post < lastdate Then
Response.Write getCurrentIcon(strIconFolder,"No New Posts","") & "</a>" & vbNewLine
Else
Response.Write getCurrentIcon(strIconFolderNew,"New Posts","") & "</a>" & vbNewLine
End If
Else
If Cat_Status = 0 Then
strAltText = "Category locked"
ElseIf Forum_Status = 0 Then
strAltText = "Forum locked"
Else
strAltText = "Topic locked"
End If
If Topic_Last_Post < lastdate Then
Response.Write getCurrentIcon(strIconFolderLocked,strAltText,"hspace=""0""")
Else
Response.Write getCurrentIcon(strIconFolderNewLocked,strAltText,"hspace=""0""")
End If
Response.Write "</a>" & vbNewLine
End If
' ## Message Icon Below
Response.Write " </td>" & vbNewLine & _
" <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center"">" & getCurrentIcon(getCurrentMsgIcon(Topic_MsgIcon),"","hspace=""0""") & "</td>" & vbNewLine & _
" <td bgcolor=""" & strForumCellColor & """ valign=""middle""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>"
' ## Message Icon Above
' ## Poll Below
If IsPoll Then Response.Write "Poll: "
' ## Poll Above
Response.Write "<span class=""spnMessageText""><a href=""topic.asp?TOPIC_ID=" & Topic_ID & """>" & ChkString(Topic_Subject,"title") & "</a></span> </font>" & vbNewLine
If strShowPaging = "1" Then
TopicPaging()
End If
Response.Write " </td>" & vbNewLine & _
" <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""><a href=""pop_profile.asp?mode=display&id="& TOPIC_AUTHOR & """><acronym style=""text-decoration:underline; border:none;"" title=""" & Member_Name & """><img src=""" & Member_Avatar & """ height=""50"" width=""50"" /></acronym></a><br /><font face=""" & strDefaultFontFace & """ size=""1"" & strDefaultFontSize & """" color=""" & strForumFontColor & """><span class=""spnMessageText"">" & profileLink(chkString(Member_Name,"display"),Topic_Author) & "</span></font></td>" & vbNewLine
if CLng(Topic_Replies) > 0 then
response.write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """><span class=""spnMessageText""><acronym title=""Click here to see who has posted in this topic. (" & ChkString(Topic_Subject,"title") & ")""><a href=""JavaScript:openWindow3('pop_posted.asp?" & ArchiveLink & "Topic_ID=" & Topic_ID & "')""" & dWStatus("Who has posted?") & "><font size=""1"">Click to see who commented<br /></font>" & Topic_Replies & "</a></acronym></span></font></td>" & vbNewLine
else
response.write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """>" & Topic_Replies & "</font></td>" & vbNewLine
end if
Response.Write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""> <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """>" & Topic_View_Count & "</font></td>" & vbNewLine
If IsNull(Topic_Last_Post_Author) Then
strLastAuthor = ""
Else
strLastAuthor = "<br />by: <a href=""pop_profile.asp?mode=display&id="& Topic_Last_Post_Author & """><acronym style=""text-decoration:underline; border:none;"" title=""" & Topic_Last_Post_Author_Name & """><img src=""" & strLPostAvatar & """ height=""50"" width=""50"" /></acronym></a>"
If strJumpLastPost = "1" Then strLastAuthor = strLastAuthor & " " & DoLastPostLink
End If
Response.Write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center"" nowrap><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """ color=""" & strForumFontColor & """><b>" & ChkDate(Topic_Last_Post, "</b> " ,true) & strLastAuthor & "</font></td>" & vbNewLine
If (mlev > 0) or (lcase(strNoCookies) = "1") Then
Response.Write " <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center"" nowrap><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine
If (ModerateAllowed = "Y") or (lcase(strNoCookies) = "1") Then
Call TopicAdminOptions
Else
If Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0 Then
Call TopicMemberOptions
Else
Response.Write " " & vbNewLine
End If
End If
Response.Write " </font></b></td>" & vbNewLine
ElseIf (mLev = 3) Then
Response.Write " <td bgcolor=""" & strForumCellColor & """> </td>" & vbNewLine
End If
Response.Write " </tr>" & vbNewLine
currForum = Forum_ID
Next
If fDisplayCount = 0 Then
Response.Write " <tr>" & vbNewLine & _
" <td colspan=""" & aGetColspan(7,6) & """ bgcolor=""" & strForumCellColor & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><b>No Active Topics Found</b></font></td>" & vbNewLine & _
" </tr>" & vbNewLine
End If
End If
Response.Write " </table>" & vbNewLine & _
" </td>" & vbNewLine & _
" </tr>" & vbNewLine & _
" </table>" & vbNewLine & _
" <table width=""100%"" border=""0"" align=""center"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td align=""left"" width=""50%"">" & vbNewLine & _
" <table>" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td>" & vbNewLine & _
" <p><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>" & vbNewLine & _
" " & getCurrentIcon(strIconFolderNew,"New Posts","align=""absmiddle""") & " New posts since last logon.<br />" & vbNewLine & _
" " & getCurrentIcon(strIconFolder,"Old Posts","align=""absmiddle""") & " Old Posts."
If lcase(strHotTopic) = "1" Then
Response.Write (" (" & getCurrentIcon(strIconFolderHot,"Hot Topic","align=""absmiddle""") & " " & intHotTopicNum & " replies or more.)<br />" & vbNewLine)
End If
Response.Write " " & getCurrentIcon(strIconFolderLocked,"Locked Topic","align=""absmiddle""") & " Locked topic.<br />" & vbNewLine
If HeldFound = "Y" Then
Response.Write " " & getCurrentIcon(strIconFolderHold,"Held Topic","align=""absmiddle""") & " Held Topic.<br />" & vbNewLine
End If
If UnapprovedFound = "Y" Then
Response.Write " " & getCurrentIcon(strIconFolderUnmoderated,"UnModerated Topic","align=""absmiddle""") & " UnModerated Topic.<br />" & vbNewLine
End If
Response.Write " </font></p></td>" & vbNewLine & _
" </tr>" & vbNewLine & _
" </table>" & vbNewLine & _
" </td>" & vbNewLine & _
" <td align=""right"" valign=""top"" width=""50%"" nowrap>" & vbNewLine
%>
<!--#INCLUDE FILE="inc_jump_to.asp" -->
<%
Response.Write " </td></tr><tr>" & vbNewline & _
" <td colspan=""" & sGetColspan(7,6) & """ bgColor=""" & strForumCellColor & """>" & vbNewline & _
" <table width=""100%"" border=""1"" style=""border-collapse:collapse;"" cellpadding=""4"" cellspacing=""1"" bgColor=""" & strTableBorderColor & """>" & vbNewline & _
" <tr>" & vbNewline
Call DisplayBirthdays(30,0)
Response.Write " </tr>" & vbNewLine & _
" </table></td></tr>" & vbNewLine & _
" <script language=""javascript"" type=""text/javascript"">" & vbNewLine & _
" <!--" & vbNewLine & _
" if (document.ReloadFrm.RefreshTime.options[document.ReloadFrm.RefreshTime.selectedIndex].value > 0) {" & vbNewline & _
" reloadTime = 60000 * document.ReloadFrm.RefreshTime.options[document.ReloadFrm.RefreshTime.selectedIndex].value" & vbNewLine & _
" self.setInterval('autoReload()', 60000 * document.ReloadFrm.RefreshTime.options[document.ReloadFrm.RefreshTime.selectedIndex].value)" & vbNewLine & _
" }" & vbNewLine & _
" //-->" & vbNewLine & _
" </script>" & vbNewLine
WriteFooter
Response.End
Sub ForumAdminOptions()
If (ModerateAllowed = "Y") or (lcase(strNoCookies) = "1") Then
If Cat_Status = 0 Then
If mlev = 4 Then
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Category&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconFolderUnlocked,"Un-Lock Category","") & "</a>" & vbNewLine
Else
Response.Write " " & getCurrentIcon(strIconFolderLocked,"Category Locked","") & vbNewLine
End If
Else
If Forum_Status <> 0 Then
Response.Write " <a href=""JavaScript:openWindow('pop_lock.asp?mode=Forum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconFolderLocked,"Lock Forum","") & "</a>" & vbNewLine
Else
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Forum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconFolderUnlocked,"Un-Lock Forum","") & "</a>" & vbNewLine
End If
End If
If (Cat_Status <> 0 and Forum_Status <> 0) or (ModerateAllowed = "Y") Then
Response.Write " <a href=""post.asp?method=EditForum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "&type=0"">" & getCurrentIcon(strIconFolderPencil,"Edit Forum Properties","hspace=""0""") & "</a>" & vbNewLine
End If
If mLev = 4 or lcase(strNoCookies) = "1" Then Response.Write(" <a href=""JavaScript:openWindow('pop_delete.asp?mode=Forum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconFolderDelete,"Delete Forum","") & "</a>" & vbNewLine)
Response.Write " <a href=""post.asp?method=Topic&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconFolderNewTopic,"New Topic","") & "</a>" & vbNewLine
If (strSubscription < 4 and strSubscription > 0) and (CatSubscription > 0) and ForumSubscription = 1 and strEmail = 1 Then
If InArray(strForumSubs, Forum_ID) Then
Response.Write ShowSubLink ("U", Cat_ID, Forum_ID, 0, "N")
ElseIf strBoardSubs <> "Y" and not(InArray(strCatSubs,Cat_ID)) Then
Response.Write ShowSubLink ("S", Cat_ID, Forum_ID, 0, "N")
End If
End If
End If
End Sub
Sub ForumMemberOptions()
If (mlev > 0) Then
Response.Write " <a href=""post.asp?method=Topic&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconFolderNewTopic,"New Topic","") & "</a>" & vbNewLine
If (strSubscription > 0 and strSubscription < 4) and CatSubscription > 0 and ForumSubscription = 1 and strEmail = 1 Then
If InArray(strForumSubs, Forum_ID) Then
Response.Write ShowSubLink ("U", Cat_ID, Forum_ID, 0, "N")
ElseIf strBoardSubs <> "Y" and not(InArray(strCatSubs,Cat_ID)) Then
Response.Write ShowSubLink ("S", Cat_ID, Forum_ID, 0, "N")
End If
End If
End If
End Sub
Sub TopicAdminOptions()
If Cat_Status = 0 Then
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Category&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconUnlock,"Un-Lock Category","hspace=""0""") & "</a>" & vbNewLine
ElseIf Forum_Status = 0 Then
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Forum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconUnlock,"Un-Lock Forum","hspace=""0""") & "</a>" & vbNewLine
ElseIf Topic_Status <> 0 Then
Response.Write " <a href=""JavaScript:openWindow('pop_lock.asp?mode=Topic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconLock,"Lock Topic","hspace=""0""") & "</a>" & vbNewLine
Else
Response.Write " <a href=""JavaScript:openWindow('pop_open.asp?mode=Topic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconUnlock,"Un-Lock Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If (ModerateAllowed = "Y") or (Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0) Then
' ## Poll Below
Response.Write " <a href=""post.asp?" & pollLink & "method=EditTopic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&auth=" & Topic_Author & """>" & getCurrentIcon(strIconPencil,"Edit Topic","hspace=""0""") & "</a>" & vbNewLine
End If
Response.Write " <a href=""JavaScript:openWindow('pop_delete.asp?" & pollLink & "mode=Topic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconTrashcan,"Delete Topic","hspace=""0""") & "</a>" & vbNewLine
' ## Poll Above
If Topic_Status <= 1 Then
Response.Write " <a href=""post.asp?method=Reply&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconReplyTopic,"Reply to Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If Topic_Status > 1 Then
TopicString = "TOPIC_ID=" & Topic_ID & "&CAT_ID=" & Cat_ID & "&FORUM_ID=" & Forum_ID
Response.Write " <a href=""JavaScript:openWindow('pop_moderate.asp?" & TopicString & "')"">" & getCurrentIcon(strIconFolderModerate,"Approve/Hold/Reject this Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If (strSubscription < 4 and strSubscription > 0) and (CatSubscription > 0) and ForumSubscription > 0 and strEmail = 1 Then
If InArray(strTopicSubs, Topic_ID) Then
Response.Write " " & ShowSubLink ("U", Cat_ID, Forum_ID, Topic_ID, "N")
ElseIf strBoardSubs <> "Y" and not(InArray(strForumSubs,Forum_ID) or InArray(strCatSubs,Cat_ID)) Then
Response.Write " " & ShowSubLink ("S", Cat_ID, Forum_ID, Topic_ID, "N")
End If
End If
End Sub
Sub TopicMemberOptions()
If (Topic_Status > 0 and Topic_Author = MemberID) or (ModerateAllowed = "Y") Then
' ## Poll Below
Response.Write " <a href=""post.asp?" & pollLink & "method=EditTopic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconPencil,"Edit Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If (Topic_Status > 0 and Topic_Author = MemberID and Topic_Replies = 0) or (ModerateAllowed = "Y") Then
Response.Write " <a href=""JavaScript:openWindow('pop_delete.asp?" & pollLink & "mode=Topic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconTrashcan,"Delete Topic","hspace=""0""") & "</a>" & vbNewLine
' ## Poll Above
End If
If Topic_Status <= 1 Then
Response.Write " <a href=""post.asp?method=Reply&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconReplyTopic,"Reply to Topic","hspace=""0""") & "</a>" & vbNewLine
End If
If (strSubscription < 4 and strSubscription > 0) and (CatSubscription > 0) and ForumSubscription > 0 and strEmail = 1 Then
If InArray(strTopicSubs, Topic_ID) Then
Response.Write " " & ShowSubLink ("U", Cat_ID, Forum_ID, Topic_ID, "N")
ElseIf strBoardSubs <> "Y" and not(InArray(strForumSubs,Forum_ID) or InArray(strCatSubs,Cat_ID)) Then
Response.Write " " & ShowSubLink ("S", Cat_ID, Forum_ID, Topic_ID, "N")
End If
End If
End Sub
Sub TopicPaging()
mxpages = (Topic_Replies / strPageSize)
If mxPages <> cLng(mxPages) Then
mxpages = int(mxpages) + 1
End If
If mxpages > 1 Then
Response.Write " <table border=""0"" cellspacing=""0"" cellpadding=""0"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td valign=""bottom""><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>" & getCurrentIcon(strIconPosticon,"","align=""absmiddle""") & "</font></td>" & vbNewLine
For counter = 1 to mxpages
ref = " <td align=""right"" valign=""bottom"" bgcolor=""" & strForumCellColor & """><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>"
If ((mxpages > 9) and (mxpages > strPageNumberSize)) or ((counter > 9) and (mxpages < strPageNumberSize)) Then
ref = ref & " "
End If
ref = ref & widenum(counter) & "<span class=""spnMessageText""><a href=""topic.asp?"
ref = ref & ArchiveLink
ref = ref & "TOPIC_ID=" & Topic_ID
ref = ref & "&whichpage=" & counter
ref = ref & """>" & counter & "</a></span></font></td>"
Response.Write ref & vbNewLine
If counter mod strPageNumberSize = 0 and counter < mxpages Then
Response.Write " </tr>" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td> </td>" & vbNewLine
End If
Next
Response.Write " </tr>" & vbNewLine & _
" </table>" & vbNewLine
End If
End Sub
Function DoLastPostLink()
If Topic_Replies < 1 or Topic_Last_Post_Reply_ID = 0 Then
DoLastPostLink = "<a href=""topic.asp?" & ArchiveLink & "TOPIC_ID=" & Topic_ID & """>" & getCurrentIcon(strIconLastpost,"Jump to Last Post","align=""absmiddle""") & "</a>"
ElseIf Topic_Last_Post_Reply_ID <> 0 Then
PageLink = "whichpage=-1&"
AnchorLink = "&REPLY_ID="
DoLastPostLink = "<a href=""topic.asp?" & ArchiveLink & PageLink & "TOPIC_ID=" & Topic_ID & AnchorLink & Topic_Last_Post_Reply_ID & """>" & getCurrentIcon(strIconLastpost,"Jump to Last Post","align=""absmiddle""") & "</a>"
Else
DoLastPostLink = ""
End If
End Function
function aGetColspan(lIN, lOUT)
If (mlev > 0 or strNoCookies = "1") Then
lOut = lOut + 1
End If
If lOut > lIn Then
aGetColspan = lIN
Else
aGetColspan = lOUT
End If
End Function
Sub DoHideCategory(intCatId)
HideForumCat = strUniqueID & "HideCat" & intCatId
If Request.QueryString(HideForumCat) = "Y" Then
Response.Cookies(HideForumCat) = "Y"
Response.Cookies(HideForumCat).Expires = dateAdd("d", 30, strForumTimeAdjust)
Else
If Request.QueryString(HideForumCat) = "N" Then
Response.Cookies(HideForumCat) = "N"
Response.Cookies(HideForumCat).Expires = dateadd("d", -2, strForumTimeAdjust)
End If
End If
End sub
%>
|
HuwR |
Posted - 16 December 2013 : 11:28:43 could you post a text copy of your active.asp so that I can ensure it works with your version when I do.
cheers. |
HuwR |
Posted - 16 December 2013 : 07:09:47 Shouldn't be too difficult, I will take a look over the christmas break and see what I can come up with. |
|
|