<% '################################################################################# '## Ver.3.4.06 multi-language Skin3D Portal '################################################################################# '## Copyright (C) 2001-07 Gaėtan Dupont All Rights Reserved '## '## By using this program, you are agreeing to the terms of the '## GNU General Public License. '## '## This program is free software; you can redistribute it and/or '## modify it under the terms of the GNU General Public License '## as published by the Free Software Foundation; either version 2 '## of the License, or (at your option) any later version. '## '## All copyright notices regarding ImageForums2001 must remain intact '## in the scripts and in the outputted HTML. '## The "Image Forums 2001" text with a link back to '## http://www.forums2001.ca in the footer of the pages MUST '## remain visible when the pages are viewed on the internet or intranet. '## '## Support can be obtained from support forums at: '## http://www.forums2001.ca '## '## Email: image_forum_2001@hotmail.com '## '################################################################################# '## This Page Contains source code of Snitz Forums 2000 '################################################################################# '## Snitz Forums 2000 v3.4.06 '################################################################################# '## Copyright (C) 2000-06 Michael Anderson, Pierre Gorissen, '## Huw Reddick and Richard Kinser '## '## This program is free software; you can redistribute it and/or '## modify it under the terms of the GNU General Public License '## as published by the Free Software Foundation; either version 2 '## of the License, or (at your option) any later version. '## '## All copyright notices regarding Snitz Forums 2000 '## must remain intact in the scripts and in the outputted HTML '## 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 the implied warranty of '## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the '## GNU General Public License for more details. '## '## You should have received a copy of the GNU General Public License '## along with this program; if not, write to the Free Software '## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. '## '## Support can be obtained from our support forums at: '## http://forum.snitz.com '## '## Correspondence and Marketing Questions can be sent to: '## manderson@snitz.com '## '################################################################################# %> <% Dim ArchiveView Dim HeldFound, UnApprovedFound, UnModeratedPosts, UnModeratedFPosts Dim HasHigherSub HasHigherSub = false if (Request("FORUM_ID") = "" or IsNumeric(Request("FORUM_ID")) = False) and (Request.Form("Method_Type") <> "login") and (Request.Form("Method_Type") <> "logout") then Response.Redirect "default.asp" else Forum_ID = cLng(Request("FORUM_ID")) end if '------------------------------------------- ' FORUM SORTING MOD VARIABLES '------------------------------------------- ' Code Mod for mypage variable dim mypage : mypage = request("whichpage") if ((Trim(mypage) = "") or IsNumeric(mypage) = False) then mypage = 1 mypage = cLng(mypage) ' Topic Sorting Variables dim strtopicsortord :strtopicsortord = request("sortorder") dim strtopicsortfld :strtopicsortfld = request("sortfield") dim strtopicsortday :strtopicsortday = request("days") dim inttotaltopics : inttotaltopics = 0 dim strSortCol, strSortOrd Select Case strtopicsortord Case "asc" strSortOrd = " ASC" Case Else strSortOrd = " DESC" strtopicsortord = "desc" End Select Select Case strtopicsortfld Case "topic" strSortCol = "T_SUBJECT" & strSortOrd Case "author" strSortCol = "M_NAME" & strSortOrd Case "replies" strSortCol = "T_REPLIES" & strSortOrd Case "views" strSortCol = "T_VIEW_COUNT" & strSortOrd Case "lastpost" strSortCol = "T_LAST_POST" & strSortOrd Case Else strtopicsortfld = "lastpost" strSortCol = "T_LAST_POST" & strSortOrd End Select strQStopicsort = "FORUM_ID=" & Forum_ID '------------------------------------------- if request("ARCHIVE") = "true" then strActivePrefix = strTablePrefix & "A_" ArchiveView = "true" ArchiveLink = "ARCHIVE=true&" elseif request("ARCHIVE") <> "" then Response.Redirect "default.asp" Response.End else strActivePrefix = strTablePrefix ArchiveView = "" ArchiveLink = "" end if %> <% nDays = Request.Cookies(strCookieURL & "NumDays") if Request.form("cookie") = 1 then if strSetCookieToForum = "1" then Response.Cookies(strCookieURL & "NumDays").Path = strCookieURL end if Response.Cookies(strCookieURL & "NumDays") = Request.Form("days") Response.Cookies(strCookieURL & "NumDays").expires = dateAdd("yyyy", 1, strForumTimeAdjust) nDays = Request.Form("Days") mypage = 1 end if if request("ARCHIVE") = "true" then nDays = "0" end if Response.Write " " & vbNewLine if mLev = 4 then AdminAllowed = 1 ForumChkSkipAllowed = 1 elseif mLev = 3 then if chkForumModerator(Forum_ID, chkString(strDBNTUserName,"decode")) = "1" then AdminAllowed = 1 ForumChkSkipAllowed = 1 else if lcase(strNoCookies) = "1" then AdminAllowed = 1 ForumChkSkipAllowed = 0 else AdminAllowed = 0 ForumChkSkipAllowed = 0 end if end if elseif lcase(strNoCookies) = "1" then AdminAllowed = 1 ForumChkSkipAllowed = 0 else AdminAllowed = 0 ForumChkSkipAllowed = 0 end if if strPrivateForums = "1" and (Request.Form("Method_Type") <> "login") and (Request.Form("Method_Type") <> "logout") and ForumChkSkipAllowed = 0 then result = ChkForumAccess(Forum_ID, MemberID, true) end if if intShowUserGroups = "1" then if strPrivateForums <> "1" and (Request.Form("Method_Type") <> "login") and (Request.Form("Method_Type") <> "logout") and ForumChkSkipAllowed = 0 then result = ChkForumAccess(Forum_ID, MemberID, true) end if end if if strModeration = "1" and AdminAllowed = 1 then UnModeratedPosts = CheckForUnModeratedPosts("FORUM", Cat_ID, Forum_ID, 0) end if ' -- Get all the high level(board, category, forum) subscriptions being held by the user 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 '## Forum_SQL - Find out the Category/Forum status and if it Exists strSql = "SELECT C.CAT_STATUS, C.CAT_SUBSCRIPTION, " & _ "C.CAT_MODERATION, C.CAT_NAME, C.CAT_ID, " & _ "F.F_TOPIC_AUTH,F.F_REPLY_AUTH, " &_ "F_POLLS, F.F_STATUS, F.F_SUBSCRIPTION, " & _ "F.F_MODERATION, F_DEFAULTDAYS, F.F_SUBJECT " & _ " FROM " & strTablePrefix & "CATEGORY C, " & _ strTablePrefix & "FORUM F " & _ " WHERE F.FORUM_ID = " & Forum_ID & _ " AND C.CAT_ID = F.CAT_ID " & _ " AND F.F_TYPE = 0" set rsCFStatus = my_Conn.Execute (StrSql) if rsCFStatus.EOF or rsCFStatus.BOF then rsCFStatus.close set rsCFStatus = nothing Response.Redirect("default.asp") else Cat_ID = rsCFStatus("CAT_ID") Cat_Name = rsCFStatus("CAT_NAME") Cat_Status = rsCFStatus("CAT_STATUS") Cat_Subscription = rsCFStatus("CAT_SUBSCRIPTION") Cat_Moderation = rsCFStatus("CAT_MODERATION") Forum_Status = rsCFStatus("F_STATUS") Forum_Subject = rsCFStatus("F_SUBJECT") Forum_Subscription = rsCFStatus("F_SUBSCRIPTION") Forum_Moderation = rsCFStatus("F_MODERATION") intTopicAuth = rsCFStatus("F_TOPIC_AUTH") intReplyAuth = rsCFStatus("F_REPLY_AUTH") if nDays = "" then nDays = rsCFStatus("F_DEFAULTDAYS") end if Forum_Polls = rsCFStatus("F_POLLS") rsCFStatus.close set rsCFStatus = nothing end if if strModeration = 1 and Cat_Moderation = 1 and (Forum_Moderation = 1 or Forum_Moderation = 2) then Moderation = "Y" end if ' DEM --> End of Code added for Moderation if nDays = "" then nDays = 30 end if defDate = DateToStr(dateadd("d",-(nDays),strForumTimeAdjust)) '## Forum_SQL - Get all topics from DB strSql ="SELECT T.T_STATUS, T.CAT_ID, T.FORUM_ID, T.TOPIC_ID, T.T_VIEW_COUNT, T.T_SUBJECT, T.T_ISPOLL," strSql = strSql & "T.T_AUTHOR, T.T_STICKY, T.T_REPLIES, T.T_UREPLIES, T.T_LAST_POST, T.T_LAST_POST_AUTHOR, " strSql = strSql & "T.T_LAST_POST_REPLY_ID, T.T_DATE, M.M_NAME, MEMBERS_1.M_NAME AS LAST_POST_AUTHOR_NAME, T.T_MSGICON " strSql = strSql & ", T.T_ISEVENT " strSql2 = " FROM " & strMemberTablePrefix & "MEMBERS M, " strSql2 = strSql2 & strActivePrefix & "TOPICS T, " strSql2 = strSql2 & strMemberTablePrefix & "MEMBERS AS MEMBERS_1 " strSql3 = " WHERE M.MEMBER_ID = T.T_AUTHOR " strSql3 = strSql3 & " AND T.T_LAST_POST_AUTHOR = MEMBERS_1.MEMBER_ID " strSql3 = strSql3 & " AND T.FORUM_ID = " & Forum_ID & " " if nDays = "-1" then if strStickyTopic = "1" then strSql3 = strSql3 & " AND (T.T_STATUS <> 0 OR T.T_STICKY = 1)" else strSql3 = strSql3 & " AND T.T_STATUS <> 0 " end if end if if nDays > "0" then if strStickyTopic = "1" then strSql3 = strSql3 & " AND (T.T_LAST_POST > '" & defDate & "' OR T.T_STICKY = 1)" else strSql3 = strSql3 & " AND T.T_LAST_POST > '" & defDate & "'" end if end if ' DEM --> if not a Moderator, all unapproved posts should not be viewed. if AdminAllowed = 0 then strSql3 = strSql3 & " AND ((T.T_AUTHOR <> " & MemberID strSql3 = strSql3 & " AND T.T_STATUS < " ' Ignore unapproved/rejected posts if Moderation = "Y" then strSql3 = strSql3 & "2" ' Ignore unapproved posts else strSql3 = strSql3 & "3" ' Ignore any hold posts end if strSql3 = strSql3 & ") OR T.T_AUTHOR = " & MemberID & ")" end if strSql4 = " ORDER BY" if strStickyTopic = "1" then strSql4 = strSql4 & " T.T_STICKY DESC, " end if if strtopicsortfld = "author" then strSql4 = strSql4 & " M." & strSortCol & " " else strSql4 = strSql4 & " T." & strSortCol & " " end if if strDBType = "mysql" then 'MySql specific code if mypage > 1 then intOffset = cLng((mypage-1) * strPageSize) strSql5 = strSql5 & " LIMIT " & intOffset & ", " & strPageSize & " " end if '## Forum_SQL - Get the total pagecount strSql1 = "SELECT COUNT(TOPIC_ID) AS PAGECOUNT " set rsCount = my_Conn.Execute(strSql1 & strSql2 & strSql3) iPageTotal = rsCount(0).value rsCount.close set rsCount = nothing If iPageTotal > 0 then inttotaltopics = iPageTotal maxpages = (iPageTotal \ strPageSize ) if iPageTotal mod strPageSize <> 0 then maxpages = maxpages + 1 end if if iPageTotal < (strPageSize + 1) then intGetRows = iPageTotal elseif (mypage * strPageSize) > iPageTotal then intGetRows = strPageSize - ((mypage * strPageSize) - iPageTotal) else intGetRows = strPageSize end if else iPageTotal = 0 inttotaltopics = iPageTotal maxpages = 0 end if if iPageTotal > 0 then set rs = Server.CreateObject("ADODB.Recordset") rs.open strSql & strSql2 & strSql3 & strSql4 & strSql5, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText arrTopicData = rs.GetRows(intGetRows) iTopicCount = UBound(arrTopicData, 2) rs.close set rs = nothing else iTopicCount = "" end if else 'end MySql specific code set rs = Server.CreateObject("ADODB.Recordset") rs.cachesize = strPageSize rs.open strSql & strSql2 & strSql3 & strSql4, my_Conn, adOpenStatic if not rs.EOF then rs.movefirst rs.pagesize = strPageSize inttotaltopics = cLng(rs.recordcount) rs.absolutepage = mypage '** maxpages = cLng(rs.pagecount) arrTopicData = rs.GetRows(strPageSize) iTopicCount = UBound(arrTopicData, 2) else iTopicCount = "" inttotaltopics = 0 end if rs.Close set rs = nothing end if Response.Write " " & vbNewLine Response.Write " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine if maxpages > 1 then Response.Write " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine else Response.Write " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine end if Response.Write "
" & vbNewLine & _ " " & getCurrentIcon(strIconFolderOpen,fLang(strLangAll_Forums00010),"align=""absmiddle""") & " " & fLang(strLangAll_Forums00010) & "
" & vbNewLine & _ " " & getCurrentIcon(strIconBar,"","align=""absmiddle""") if Cat_Status <> 0 then Response.Write getCurrentIcon(strIconFolderOpen,"","align=""absmiddle""") else Response.Write getCurrentIcon(strIconFolderClosed,"","align=""absmiddle""") end if Response.Write " " & ChkString(Cat_Name,"display") & "
" & vbNewLine & _ " " & getCurrentIcon(strIconBlank,"","align=""absmiddle""") & getCurrentIcon(strIconBar,"","align=""absmiddle""") if ArchiveView = "true" then Response.Write getCurrentIcon(strIconFolderArchived,"","align=""absmiddle""") else if Cat_Status <> 0 and Forum_Status <> 0 then Response.Write getCurrentIcon(strIconFolderOpenTopic,"","align=""absmiddle""") else Response.Write getCurrentIcon(strIconFolderClosedTopic,"","align=""absmiddle""") end if end if Response.Write " " & ChkString(Forum_Subject,"display") & "" & vbNewLine Response.write "

" & vbNewLine Response.write "" select case intTopicAuth case 1 response.write "   " & fLang(strLangRestrictions00010) case 3 response.write "   " & fLang(strLangRestrictions00020) case 4 response.write "   " & fLang(strLangRestrictions00030) case else end select select case intReplyAuth case 1 response.write "
   " & fLang(strLangRestrictions00040) case 3 response.write "
   " & fLang(strLangRestrictions00050) case 4 response.write "
   " & fLang(strLangRestrictions00060) case else end select Response.write "
" Response.Write "
" & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ "
" & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine Call DropDownPaging(1) Response.Write " " & vbNewLine & _ "
" & vbNewLine & _ "

" & vbNewLine %> <% '***Begin Top of left column*** %> <% if intForumMainMenu = 1 then If flag_showmainmenu then Response.Write "" & vbNewLine & _ "" & vbNewLine & _ "" & vbNewLine & _ "" & vbNewLine & _ "" & vbNewline & _ " " & vbNewline & _ "
" & vbNewLine %> <% Response.Write "" & vbNewLine & _ "" & vbNewLine end if end if %> <% '***End Top of left column*** %> <% Response.Write "" & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ "
" & vbNewLine & _ " " & vbNewLine call PostNewTopic() Response.Write "
" & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine if maxpages > 1 then Response.Write " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine else Response.Write " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine end if Response.Write "
" & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine if intMessageIcons = "1" then Response.Write(" " & vbNewLine) Response.Write " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine if intTopicRating = "1" then Response.Write(" " & vbNewLine) Response.Write " " & vbNewLine if mlev > 0 or (lcase(strNoCookies) = "1") then Response.Write " " & vbNewLine end if Response.Write " " & vbNewLine if intAnnouncements = "1" then %><% end if if iTopicCount = "" then if intMessageIcons = "1" and intTopicRating = "1" then MIColspan = "9" else MIColspan = "8" end if Response.Write " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine else tT_STATUS = 0 tCAT_ID = 1 tFORUM_ID = 2 tTOPIC_ID = 3 tT_VIEW_COUNT = 4 tT_SUBJECT = 5 tIS_POLL = 6 tT_AUTHOR = 7 tT_STICKY = 8 tT_REPLIES = 9 tT_UREPLIES = 10 tT_LAST_POST = 11 tT_LAST_POST_AUTHOR = 12 tT_LAST_POST_REPLY_ID = 13 tT_DATE = 14 tM_NAME = 15 tLAST_POST_AUTHOR_NAME = 16 tT_MSGICON = 17 tT_ISEVENT = 18 rec = 1 for iTopic = 0 to iTopicCount if (rec = strPageSize + 1) then exit for Topic_Status = arrTopicData(tT_STATUS, iTopic) Topic_CatID = arrTopicData(tCAT_ID, iTopic) Topic_ForumID = arrTopicData(tFORUM_ID, iTopic) Topic_ID = arrTopicData(tTOPIC_ID, iTopic) Topic_ViewCount = arrTopicData(tT_VIEW_COUNT, iTopic) Topic_Subject = arrTopicData(tT_SUBJECT, iTopic) IsPoll = arrTopicData(tIS_POLL, iTopic) if IsPoll = 1 then pollLink = "poll=1&" else pollLink = "" end if Topic_Author = arrTopicData(tT_AUTHOR, iTopic) Topic_Sticky = arrTopicData(tT_STICKY, iTopic) Topic_Replies = arrTopicData(tT_REPLIES, iTopic) Topic_UReplies = arrTopicData(tT_UREPLIES, iTopic) Topic_LastPost = arrTopicData(tT_LAST_POST, iTopic) Topic_LastPostAuthor = arrTopicData(tT_LAST_POST_AUTHOR, iTopic) Topic_LastPostReplyID = arrTopicData(tT_LAST_POST_REPLY_ID, iTopic) Topic_Date = arrTopicData(tT_DATE, iTopic) Topic_MName = arrTopicData(tM_NAME, iTopic) Topic_LastPostAuthorName = arrTopicData(tLAST_POST_AUTHOR_NAME, iTopic) Topic_MsgIcon = arrTopicData(tT_MSGICON, iTopic) Isevent = arrTopicData(tT_ISEVENT, iTopic) TopicRatingAvg = GetTopicRatingAvg( TOPIC_ID ) if AdminAllowed = 1 and Topic_UReplies > 0 then Topic_Replies = Topic_Replies + Topic_UReplies end if Response.Write " " & vbNewLine & _ " " & vbNewLine if intMessageIcons = "1" then if strUseBugForm = "1" and Topic_ForumID = cLng(intBugFormForum) then Response.Write " " & vbNewLine else Response.Write " " & vbNewLine end if end if Response.Write " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine if intTopicRating = "1" then Response.Write " " & vbNewLine end if if IsNull(Topic_LastPostAuthor) then strLastAuthor = "" else strLastAuthor = "
" & fLang(strLangBy00010) & " " & profileLink(ChkString(Topic_LastPostAuthorName, "display"),Topic_LastPostAuthor) & "" if (strJumpLastPost = "1") then strLastAuthor = strLastAuthor & " " & DoLastPostLink end if Response.Write " " & vbNewLine if mlev > 0 or (lcase(strNoCookies) = "1") then Response.Write " " & vbNewLine end if Response.Write " " & vbNewLine rec = rec + 1 next end if if intMessageIcons = "1" and intTopicRating = "1" then MIColspan2 = "8" elseif intTopicRating = "1" then MIColspan2 = "7" elseif intMessageIcons = "1" then MIColspan2 = "7" else MIColspan2 = "6" end if Response.Write " " & vbNewLine & _ " " & vbNewLine if mLev > 0 or (lcase(strNoCookies) = "1") then Response.Write " " & vbNewLine end if Response.Write " " & vbNewLine Response.Write "
  " & fLang(strLangHead_Topic00010) & "" & fLang(strLangAuthor00010) & "" & fLang(strLangReplies00010) & "" & fLang(strLangRead00010) & "" & fLang(strLangTopic_Rating00010) & "" & fLang(strLangLast_Post00010) & "" & vbNewLine if (AdminAllowed = 1) then call ForumAdminOptions else Response.Write "  " & vbNewLine end if Response.Write "
" & fLang(strLangForum00180) & "
" if Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0 then if Topic_Sticky and strStickyTopic = "1" then if Topic_LastPost > Session(strCookieURL & "last_here_date") then Response.Write getCurrentIcon(strIconFolderNewSticky,fLang(strLangForum00190),"hspace=""0""") else Response.Write getCurrentIcon(strIconFolderSticky,fLang(strLangForum00200),"hspace=""0""") end if else ' DEM --> Added code for topic moderation if Topic_Status = 2 then UnApprovedFound = "Y" Response.Write getCurrentIcon(strIconFolderUnmoderated,fLang(strLangNot_Moderated00010),"hspace=""0""") elseif Topic_Status = 3 then HeldFound = "Y" Response.Write getCurrentIcon(strIconFolderHold,fLang(strLangTopic_Hold00010),"hspace=""0""") ' DEM --> end of code Added for topic moderation else Response.Write ChkIsNew(Topic_LastPost) end if end if else if ArchiveView <> "true" then if Cat_Status = 0 then strAltText = fLang(strLangCategory_Locked00010) elseif Forum_Status = 0 then strAltText = fLang(strLangForum_Locked00010) else strAltText = fLang(strLangForum00250) end if end if if ArchiveView = "true" then Response.Write getCurrentIcon(strIconFolderArchived,fLang(strLangForum00260),"hspace=""0""") elseif Topic_LastPost > Session(strCookieURL & "last_here_date") then if Topic_Sticky and strStickyTopic = "1" then Response.Write getCurrentIcon(strIconFolderNewStickyLocked,strAltText,"hspace=""0""") else Response.Write getCurrentIcon(strIconFolderNewLocked,strAltText,fLang(strLangLocked00010)) end if else if Topic_Sticky and strStickyTopic = "1" then Response.Write getCurrentIcon(strIconFolderStickyLocked,strAltText,"hspace=""0""") else Response.Write getCurrentIcon(strIconFolderLocked,strAltText,fLang(strLangLocked00010)) end if end if end if Response.Write "" & vbNewLine if isevent="1" then Response.Write getCurrentIcon(strIconEvent,"","") elseif IsPoll="1" then Response.Write getCurrentIcon(strIconPoll2,"","") elseif Topic_Status = 11 then Response.Write getCurrentIcon(strIconTopicSecret,fLang(strLangTopic01010),"align=""absmiddle""") else Response.Write getCurrentIcon(strIconBugSmall,fLang(strLangBug00440),"hspace=""0""") end if Response.Write "" & vbNewLine if isevent="1" then Response.Write getCurrentIcon(strIconEvent,"","") elseif IsPoll="1" then Response.Write getCurrentIcon(strIconPoll2,"","") elseif Topic_Status = 11 then Response.Write getCurrentIcon(strIconTopicSecret,fLang(strLangTopic01010),"align=""absmiddle""") else Response.Write getCurrentIcon(getCurrentMsgIcon(Topic_MsgIcon),"","hspace=""0""") end if Response.Write "" & vbNewLine & _ " " 'if Topic_Sticky and strStickyTopic = "1" then Response.Write fLang(strLangForum00270) if Topic_Sticky and strStickyTopic = "1" and IsPoll then Response.Write fLang(strLangForum00860) elseif Topic_Sticky and strStickyTopic = "1" and not(IsPoll) then Response.Write fLang(strLangForum00270) elseif IsPoll then Response.Write fLang(strLangForum00870) end if if Isevent="1" then Response.Write fLang(strLangCla00190) if Topic_Status = 11 then Response.Write fLang(strLangTopic01020) Response.Write "" & ChkString(Topic_Subject,"title") & " " & vbNewLine if strShowPaging = "1" then Call TopicPaging() end if Response.Write " " & profileLink(chkString(Topic_MName,"display"),Topic_Author) & "" 'strTopicDate = mid(Topic_Date,5,2) & "/" & mid(Topic_Date,7,2) & "/" & mid(Topic_Date,3,2) response.write "
" & ChkDate(Topic_Date, "" ,false) & "" Response.Write "
" & Topic_Replies & "" & Topic_ViewCount & "" if intShowRatingStars = "1" then Response.Write("" & getCurrentIcon(GetTopicRatingPicture(TopicRatingAvg),"","") & "") else Response.Write("" & TopicRatingAvg & "") Response.Write "" & ChkDate(Topic_LastPost," -",true) & strLastAuthor & "" & vbNewLine if AdminAllowed = 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 "
" & vbNewLine dim topicreclow, topicrechigh, topicpage topicpage = mypage if (topicpage <= 1) then topicreclow = 1 else topicreclow = ((topicpage - 1) * strPageSize) + 1 end if topicrechigh = topicreclow + (rec - 2) Response.Write "
" & vbNewLine if ArchiveView = "true" then Response.Write " " & vbNewLine Response.Write " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ "
" if inttotaltopics = 0 then Response.Write fLang(strLangForum00180) elseif topicreclow = topicrechigh then Response.Write fLangN(strLangForum00290, topicreclow & "|" & inttotaltopics) else Response.Write fLangN(strLangForum00300, topicreclow & "|" & topicrechigh & "|" & inttotaltopics) end if Response.Write " " & fLang(strLangForum00310) & "  " & fLang(strLangForum00370) & "  " & fLang(strLangForum00400) & " " & vbNewLine & _ "
" & vbNewLine & _ "
" & vbNewLine & _ "
" if (AdminAllowed = 1) then call ForumAdminOptions else Response.Write "  " & vbNewLine end if Response.Write "
" & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ "
" & vbNewLine & _ " " & vbNewLine call PostNewTopic() Response.Write "
" & vbNewLine & _ "
" & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine Call DropDownPaging(2) Response.Write " " & vbNewLine & _ "
" & vbNewLine & _ "

" & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ "
" & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ " " & vbNewLine & _ "
" & vbNewLine & _ "

" & vbNewLine & _ " " & getCurrentIcon(strIconFolderNew,fLang(strLangNew_Posts00010),"align=""absmiddle""") & " " & fLang(strLangLast_Logon00010) & "
" & vbNewLine & _ " " & getCurrentIcon(strIconFolder,fLang(strLangOld_Posts00010),"align=""absmiddle""") & " " & fLang(strLangOld_Posts200010) & " " if lcase(strHotTopic) = "1" then Response.Write (" (" & getCurrentIcon(strIconFolderHot,fLang(strLangHot_Topic00010),"align=""absmiddle""") & " " & fLangN(strLangReplies_More00010,intHotTopicNum) & "
" & vbNewLine) Response.Write " " & getCurrentIcon(strIconFolderLocked,fLang(strLangLockedTopic00010),"align=""absmiddle""") & " " & fLang(strLangLocked_Topic00010) & "
" & vbNewLine ' DEM --> Start of Code added for moderation if HeldFound = "Y" then Response.Write " " & getCurrentIcon(strIconFolderHold,fLang(strLangHeldTopic00010),"align=""absmiddle""") & " " & fLang(strLangHeld_Topic00010) & "
" & vbNewline end if if UnapprovedFound = "Y" then Response.Write " " & getCurrentIcon(strIconFolderUnmoderated,fLang(strLangUnModerated00010),"align=""absmiddle""") & " " & fLang(strLangUn_Moderated00010) & "
" & vbNewline end if ' DEM --> End of Code added for moderation Response.Write "

" & vbNewLine & _ "
" & vbNewLine %><% Response.Write "
" & vbNewLine '***End of left column*** if intForumMainMenu = 1 then If flag_showmainmenu then Response.Write "
" & vbNewline end if end if '***End of left column*** WriteFooter Response.End sub PostNewTopic() ' select case intTopicAuth ' case 3 ' if mLev < 3 then exit sub ' case 4 ' if mLev < 4 then exit sub ' case else ' end select if Cat_Status = 0 or Forum_Status = 0 then if (AdminAllowed = 1) and (mlev >= intTopicAuth) then if intShowEvents = "1" then if mlev >= intAllowedtoPostEvent then Response.Write " " & getCurrentIcon(strIconEvent,strCalNewEvent,"align=""absmiddle""") & " " & fLang(strLangCla00150) & " |" & vbNewLine end if Response.Write " " & getCurrentIcon(strIconFolderLocked,fLang(strLangCategory_Locked00010),"align=""absmiddle""") & " " & fLang(strLangNew_Topic00010) & "" & vbNewLine if strUseBugform = "1" and mlev >= 2 then Response.Write "| " & getCurrentIcon(strIconBugSmall,fLang(strLangBug00450),"align=""absmiddle""") & " " & fLang(strLangBug00450) & "" & vbNewLine end if else Response.Write " " & getCurrentIcon(strIconFolderLocked,fLang(strLangCategory_Locked00010),"align=""absmiddle""") & " " & fLang(strLangCategory_Locked00010) & vbNewLine if strUseBugform = "1" and mlev >= 2 then Response.Write "| " & getCurrentIcon(strIconBugSmall,fLang(strLangBug00450),"align=""absmiddle""") & " " & fLang(strLangBug00450) & "" & vbNewLine end if end if else if Forum_Status <> 0 then if mlev >= intTopicAuth then if intShowEvents = "1" then if mlev >= intAllowedtoPostEvent then Response.Write " " & getCurrentIcon(strIconEvent,strCalNewEvent,"align=""absmiddle""") & " " & fLang(strLangCla00150) & " |" & vbNewLine end if Response.Write " " & getCurrentIcon(strIconFolderNewTopic,fLang(strLangNew_Topic00010),"align=""absmiddle""") & " " & fLang(strLangNew_Topic00010) & "" & vbNewLine if strPolls = "1" and ((Forum_Polls = "2" and AdminAllowed = 1) or (Forum_Polls = "1")) then Response.Write "| " & getCurrentIcon(strIconPoll,fLang(strLangNew_Poll00010),"align=""absmiddle""") & " " & fLang(strLangNew_Poll00010) & "" & vbNewLine end if if strUseBugform = "1" and mlev >= 2 then Response.Write "| " & getCurrentIcon(strIconBugSmall,fLang(strLangBug00450),"align=""absmiddle""") & " " & fLang(strLangBug00450) & "" & vbNewLine end if end if else Response.Write " " & getCurrentIcon(strIconFolderLocked,fLang(strLangForum_Locked00010),"align=""absmiddle""") & " " & fLang(strLangForum_Locked00010) & vbNewLine if strUseBugform = "1" and mlev >= 2 then Response.Write "| " & getCurrentIcon(strIconBugSmall,fLang(strLangBug00450),"align=""absmiddle""") & " " & fLang(strLangBug00450) & " |" & vbNewLine end if end if end if ' DEM --> Start of Code added to handle subscription processing. if (strSubscription < 4 and strSubscription > 0) and (Cat_Subscription > 0) and Forum_Subscription = 1 and (mlev > 0) and strEmail = 1 then Response.Write " " if InArray(strForumSubs, Forum_ID) then Response.Write "| " & ShowSubLink ("U", Cat_ID, Forum_ID, 0, "Y") & vbNewLine elseif strBoardSubs <> "Y" and not(InArray(strCatSubs,Cat_ID)) then Response.Write "| " & ShowSubLink ("S", Cat_ID, Forum_ID, 0, "Y") & vbNewLine end if end if ' DEM --> End of code added to handle subscription processing. end sub sub ForumAdminOptions() if (AdminAllowed = 1) then if Cat_Status = 0 then if mlev = 4 then Response.Write " " & getCurrentIcon(strIconFolderUnlocked,fLang(strLangUnLock_Category00010),"") & "" & vbNewLine else Response.Write " " & getCurrentIcon(strIconFolderLocked,fLang(strLangCategory_Locked00010),"") & vbNewLine end if else if Forum_Status <> 0 then Response.Write " " & getCurrentIcon(strIconFolderLocked,fLang(strLangLock_Forum00010),"") & "" & vbNewLine else Response.Write " " & getCurrentIcon(strIconFolderUnlocked,fLang(strLangForum_Locked00010),"") & "" & vbNewLine end if end if if (Cat_Status <> 0 and Forum_Status <> 0) or (AdminAllowed = 1) then Response.Write " " & getCurrentIcon(strIconFolderPencil,fLang(strLangForum_Properties00010),"hspace=""0""") & "" & vbNewLine end if if mLev = 4 or (lcase(strNoCookies) = "1") then Response.Write " " & getCurrentIcon(strIconFolderDelete,fLang(strLangDelete_Forum00010),"") & "" & vbNewLine if strArchiveState = "1" then Response.Write(" " & getCurrentIcon(strIconFolderArchive,fLang(strLangArchive_Forum00010),"") & "" & vbNewLine) end if ' DEM --> Start of Code for Moderated Posting if (UnModeratedPosts > 0) and (AdminAllowed = 1) then Response.Write " " & getCurrentIcon(strIconFolderModerate,fLang(strLangAll_UnModerated00010),"") & "" & vbNewline end if ' DEM --> End of Code for Moderated Posting end if end sub sub DropDownPaging(fnum) if maxpages > 1 then if mypage = "" then pge = 1 else pge = mypage end if scriptname = request.servervariables("script_name") Response.write "
" & vbNewLine Response.Write " " & vbNewLine Response.write " " & vbNewLine Response.write " " & vbNewLine Response.write " " & vbNewLine if ArchiveView = "true" then Response.write " " & vbNewLine if fnum = 1 then Response.Write(" " & fLang(strLangForum00740) & " " & vbNewLine) end if for counter = 1 to maxpages if counter <> cLng(pge) then Response.Write " " & vbNewLine else Response.Write " " & vbNewLine end if next if fnum = 1 then Response.Write(" " & fLangN(strLangOf00010,maxPages) & "" & vbNewLine) else Response.Write(" " & vbNewLine) end if Response.Write(" " & vbNewLine) Response.Write("
" & vbNewLine) end if end sub sub TopicPaging() page_limit = 5 first_pages = 3 last_pages = 3 mxpages = (Topic_Replies / strPageSize) if mxPages <> cLng(mxPages) then mxpages = int(mxpages) + 1 end if if mxpages > 1 then Response.Write(" " & vbNewLine) Response.Write(" " & vbNewLine) Response.Write(" " & vbNewLine) if mxpages > page_limit then ref = " " for counter = 1 to first_pages ref = ref & " " next ref = ref & " " if last_pages = 0 then ref = ref & " " else for counter = (mxpages-last_pages+1) to mxpages ref = ref & " " next end if Response.Write ref & vbNewLine else for counter = 1 to mxpages ref = " " Response.Write ref & vbNewLine if counter mod strPageNumberSize = 0 and counter < mxpages then Response.Write(" " & vbNewLine) Response.Write(" " & vbNewLine) Response.Write(" " & vbNewLine) end if next end if Response.Write(" " & vbNewLine) Response.Write("
" & getCurrentIcon(strIconPosticon,"","") & "" ref = ref & " " & fLang(strLangPages00010) & " ("& mxpages & "): " ref = ref & widenum(counter) & " " & counter & "" ref = ref & " ...." ref = ref & widenum(counter) & " Last »" ref = ref & widenum(counter) & " " & counter & " " if ((mxpages > 9) and (mxpages > strPageNumberSize)) or ((counter > 9) and (mxpages < strPageNumberSize)) then ref = ref & " " end if ref = ref & widenum(counter) & "" & counter & "
 
" & vbNewLine) end if end sub sub TopicAdminOptions() if strStickyTopic = "1" then if Topic_Sticky then Response.Write " " & getCurrentIcon(strIconGoDown,fLang(strLangForum00770),"hspace=""0""") & "" & vbNewLine else Response.Write " " & getCurrentIcon(strIconGoUp,fLang(strLangForum00780),"hspace=""0""") & "" & vbNewLine end if end if if Cat_Status = 0 then Response.Write " " & getCurrentIcon(strIconUnlock,fLang(strLangUnLock_Category00010),"hspace=""0""") & "" & vbNewLine else if Forum_Status = 0 then Response.Write " " & getCurrentIcon(strIconUnlock,fLang(strLangUnLock_Forum00010),"hspace=""0""") & "" & vbNewLine else if Topic_Status <> 0 then Response.Write " " & getCurrentIcon(strIconLock,fLang(strLangLock_Topic00010),"hspace=""0""") & "" & vbNewLine else Response.Write " " & getCurrentIcon(strIconUnlock,fLang(strLangUnLock_Topic00010),"hspace=""0""") & "" & vbNewLine end if end if end if if (AdminAllowed = 1) or (Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0) then Response.Write " " & getCurrentIcon(strIconPencil,fLang(strLangEdit_Topic00010),"hspace=""0""") & "" & vbNewLine end if Response.Write " " & getCurrentIcon(strIconTrashcan,fLang(strLangDelete_Topic00010),"hspace=""0""") & "" & vbNewLine if Topic_Status <= 1 and ArchiveView = "" then Response.Write " " & getCurrentIcon(strIconReplyTopic,fLang(strLangReply_to_Topic00010),"hspace=""0""") & "" & vbNewLine end if ' DEM --> Start of Code for Full Moderation if Topic_Status > 1 then if strSecretTopic = "1" and Topic_Status = 11 then Response.Write " " & getCurrentIcon(strIconReplyTopicSecret,fLang(strLangTopic01030),"hspace=""0""") & "" & vbNewLine else TopicString = "TOPIC_ID=" & Topic_ID & "&CAT_ID=" & Cat_ID & "&FORUM_ID=" & Forum_ID Response.Write " " & getCurrentIcon(strIconFolderModerate,fLang(strLangApproveHoldReject_Topic00010),"hspace=""0""") & "" & vbNewline end if end if ' DEM --> End of Code for Full Moderation ' DEM --> Start of Code added to handle subscription processing. if (strSubscription > 0) and (Cat_Subscription > 0) and Forum_Subscription > 0 and strEmail = 1 then Response.Write " " if InArray(strTopicSubs, Topic_ID) then Response.Write ShowSubLink ("U", Cat_ID, Forum_ID, Topic_ID, "N") & vbNewLine 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") & vbNewLine end if end if ' DEM --> End of code added to handle subscription processing. end sub sub TopicMemberOptions() if ((Topic_Status > 0 and Topic_Author = MemberID) or (AdminAllowed = 1)) and ArchiveView = "" then Response.Write " " & getCurrentIcon(strIconPencil,fLang(strLangEdit_Topic00010),"hspace=""0""") & "" & vbNewLine if strSecretTopic = "1" and Topic_Status = 11 then if mlev >= IntReplyAuth then Response.Write " " & getCurrentIcon(strIconReplyTopicSecret,fLang(strLangTopic01030),"hspace=""0""") & "" & vbNewLine else Response.Write " " end if end if end if if ((Topic_Status > 0 and Topic_Author = MemberID and Topic_Replies = 0) or (AdminAllowed = 1)) and ArchiveView = "" then Response.Write " " & getCurrentIcon(strIconTrashcan,fLang(strLangDelete_Topic00010),"hspace=""0""") & "" & vbNewLine end if if Topic_Status <= 1 and ArchiveView = "" then if mlev >= IntReplyAuth then Response.Write " " & getCurrentIcon(strIconReplyTopic,fLang(strLangReply_to_Topic00010),"hspace=""0""") & "" & vbNewLine else Response.Write " " end if end if ' DEM --> Start of Code added to handle subscription processing. if (strSubscription > 0) and (Cat_Subscription > 0) and Forum_Subscription > 0 and strEmail = 1 then Response.Write " " if InArray(strTopicSubs, Topic_ID) then Response.Write ShowSubLink ("U", Cat_ID, Forum_ID, Topic_ID, "N") & vbNewLine 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") & vbNewLine end if end if ' DEM --> End of code added to handle subscription processing. end sub Function DoLastPostLink() if Topic_Replies < 1 or Topic_LastPostReplyID = 0 then DoLastPostLink = "" & getCurrentIcon(strIconLastpost,fLang(strLangJump_Last_Post00010),"align=""absmiddle""") & "" elseif Topic_LastPostReplyID <> 0 then PageLink = "whichpage=-1&" AnchorLink = "&REPLY_ID=" DoLastPostLink = "" & getCurrentIcon(strIconLastpost,fLang(strLangJump_Last_Post00010),"align=""absmiddle""") & "" else DoLastPostLink = "" end if end function function CheckSelected(chkval1, chkval2) if IsNumeric(chkval1) then chkval1 = cLng(chkval1) if (chkval1 = chkval2) then CheckSelected = " selected" else CheckSelected = "" end if end function %>