Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Help Groups for Snitz Forums 2000 Users
 Help: General / Classic ASP versions(v3.4.XX)
 Search Results
 New Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Maxime
Average Member

France
521 Posts

Posted - 08 October 2014 :  23:01:17  Show Profile  Visit Maxime's Homepage  Reply with Quote
Hello,

Search Results

in the results of the search function, if I have mods installed as pdf, mp3, media etc. These are not displayed, such as a youtube video, I have to go to the original page of the message to see the buttons in the video. There is there a mache to follow all this is visible in the search results?

search.asp in french
<%
'#################################################################################
'## Snitz Forums 2000 v3.4.07
'#################################################################################
'## Copyright (C) 2000-09 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
'##
'#################################################################################
%>
<!--#INCLUDE FILE="config.asp"-->
<%
Dim HasHigherSub
Dim HeldFound, UnApprovedFound, UnModeratedPosts, UnModeratedFPosts
Dim canView
HasHigherSub = false
Dim strUseMemberDropDownBox
strUseMemberDropDownBox = 0
%>
<!--#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_moderation.asp" -->
<!--#INCLUDE FILE="inc_subscription.asp" -->
<% 
Dim ArchiveView
Dim AdminAllowed, ModerateAllowed
Dim SearchLink : SearchLink = ""
if request("ARCHIVE") = "true" then
	strActivePrefix = strArchiveTablePrefix
	ArchiveView = "true"
	ArchiveLink = "ARCHIVE=true&"
else
	strActivePrefix = strTablePrefix
	ArchiveView = ""
	ArchiveLink = ""
end if

select case cLng(Request.Form("andor"))
	case 1 : strAndOr = " and "
	case 2 : strAndOr = " or "
	case 3 : strAndOr = "phrase"
	case else : strAndOr = " and "
end select

Response.Write	"    <script language=""JavaScript"" type=""text/javascript"">" & vbNewLine & _
		"    function ChangePage(fnum){" & vbNewLine & _
		"    	if (fnum == 1) {" & vbNewLine & _
		"    		document.PageNum1.submit();" & vbNewLine & _
		"    		}" & vbNewLine & _
		"    	else {" & vbNewLine & _
		"    		document.PageNum2.submit();" & vbNewLine & _
		"    	}" & vbNewLine & _
		"    }" & vbNewLine & _
		"    </script>" & vbNewLine

' -- 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

' DEM --> Added code for topic moderation
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

if Request.QueryString("mode") = "DoIt" then
	if trim(Request.Form("Search")) <> "" or Request.QueryString("MEMBER_ID") <> "" then
		if Request.Form("Search") <> "" then
			keywords = split(Request.Form("Search"), " ")
			keycnt = ubound(keywords)
			for i = 0 to keycnt
				if i = 0 then
					strKeywords = keywords(i)
				else
					strKeywords = strKeywords & "," & keywords(i)
				end if
			next
			if strAndOr = "phrase" then strKeyWords = replace(strKeyWords,",","+")
			SearchLink = "&SearchTerms=" & chkString(strKeyWords,"search")
		end if

		'## Forum_SQL - Find all records with the search criteria in them
		strSql = "SELECT DISTINCT C.CAT_STATUS, C.CAT_SUBSCRIPTION, C.CAT_NAME, C.CAT_ORDER"
		strSql = strSql & ", F.F_ORDER, F.FORUM_ID, F.F_SUBJECT, F.CAT_ID"
		strSql = strSql & ", F.F_SUBSCRIPTION, F.F_STATUS"
		strSql = strSql & ", T.TOPIC_ID, T.T_AUTHOR, T.T_SUBJECT, T.T_STATUS, T.T_LAST_POST"
		strSql = strSql & ", T.T_LAST_POST_AUTHOR, T.T_LAST_POST_REPLY_ID, T.T_REPLIES, T.T_UREPLIES, T.T_VIEW_COUNT"
		strSql = strSql & ", M.MEMBER_ID, M.M_NAME, MEMBERS_1.M_NAME AS LAST_POST_AUTHOR_NAME"
		strSql = strSql & ", F.F_PRIVATEFORUMS, F.F_PASSWORD_NEW"

		strSql2 = " FROM ((((" & strTablePrefix & "FORUM F LEFT JOIN " & strActivePrefix & "TOPICS T"
		strSql2 = strSql2 & " ON F.FORUM_ID = T.FORUM_ID) LEFT JOIN " & strActivePrefix & "REPLY R"
		strSql2 = strSql2 & " ON T.TOPIC_ID = R.TOPIC_ID) LEFT JOIN " & strMemberTablePrefix & "MEMBERS M"
		strSql2 = strSql2 & " ON T.T_AUTHOR = M.MEMBER_ID) LEFT JOIN " & strTablePrefix & "CATEGORY C"
		strSql2 = strSql2 & " ON T.CAT_ID = C.CAT_ID) LEFT JOIN " & strMemberTablePrefix & "MEMBERS MEMBERS_1"
		strSql2 = strSql2 & " ON T.T_LAST_POST_AUTHOR = MEMBERS_1.MEMBER_ID"
		if Request.Form("Search") <> "" then
			strSql3 = " WHERE ("
			'################# New Search Code #################################################
			if Request.Form("SearchMessage") = 1 then
				if strAndOr = "phrase" then
					strSql3 = strSql3 & " (T.T_SUBJECT LIKE '%" & ChkString(Request.Form("Search"), "SQLString") & "%') "
				else
					For Each word in keywords
						SearchWord = ChkString(word, "SQLString")
						strSql3 = strSql3 & " (T.T_SUBJECT LIKE '%" & SearchWord & "%') "
						if cnt < keycnt then strSql3 = strSql3 & strAndOr
						cnt = cnt + 1
					next
				end if
			else
				if strAndOr = "phrase" then
					strSql3 = strSql3 & " (R.R_MESSAGE LIKE '%" & ChkString(Request.Form("Search"), "SQLString") & "%'"
					strSql3 = strSql3 & " OR T.T_SUBJECT LIKE '%" & ChkString(Request.Form("Search"), "SQLString") & "%'"
					strSql3 = strSql3 & " OR T.T_MESSAGE LIKE '%" & ChkString(Request.Form("Search"), "SQLString") & "%') "
				else
					For Each word in keywords
						SearchWord = ChkString(word, "SQLString")
						strSql3 = strSql3 & " (R.R_MESSAGE LIKE '%" & SearchWord & "%'"
						strSql3 = strSql3 & " OR T.T_SUBJECT LIKE '%" & SearchWord & "%'"
						strSql3 = strSql3 & " OR T.T_MESSAGE LIKE '%" & SearchWord & "%') "
						if cnt < keycnt then strSql3 = strSql3 & strAndOr
						cnt = cnt + 1
					next
				end if
			'################# New Search Code #################################################
			end if
			strSql3 = strSql3 & " ) "
		else
			strSql3 = " WHERE (0 = 0)"
		end if
		' DEM --> Added code to ignore unmoderated/held posts...
		if mlev <> 4 then 
			strSql3 = strSql3 & " AND ((T.T_AUTHOR <> " & MemberID
			strSql3 = strSql3 & " AND T.T_STATUS < 2)"  ' Ignore unapproved/held posts
			strSql3 = strSql3 & " OR T.T_AUTHOR = " & MemberID & ")"
		end if
		' DEM --> End of Code added to ignore unmoderated/held posts....
		cnt = 0
		if cLng(Request.Form("Forum")) <> 0 then
			strSql3 = strSql3 & " AND F.FORUM_ID = " & cLng(Request.Form("Forum")) & " "
		end if
		if cLng(Request.Form("SearchDate")) <> 0 then
			dt = cLng(Request.Form("SearchDate"))
			strSql3 = strSql3 & " AND ( (T.T_DATE > '" & DateToStr(dateadd("d", -dt, strForumTimeAdjust)) & "') " 
			strSql3 = strSql3 & "OR (R.R_DATE > '" & DateToStr(dateadd("d", -dt, strForumTimeAdjust)) & "') ) "
		end if
		if strUseMemberDropDownBox = 0 then
			intSearchMember = getMemberID(chkString(Request.Form("SearchMember"),"SQLString"))
			if intSearchMember <> 0 then
				strSql3 = strSql3 & " AND (M.MEMBER_ID = " & cLng(intSearchMember) & " "
				strSql3 = strSql3 & " OR R.R_AUTHOR = " & cLng(intSearchMember) & ") "
			end if
		else
			if cLng(Request.Form("SearchMember")) <> 0 then
				strSql3 = strSql3 & " AND (M.MEMBER_ID = " & cLng(Request.Form("SearchMember")) & " "
				strSql3 = strSql3 & " OR R.R_AUTHOR = " & cLng(Request.Form("SearchMember")) & ") "
			end if
		end if
		if cLng(Request.QueryString("MEMBER_ID")) <> 0 then
			strSql3 = strSql3 & " AND (M.MEMBER_ID = " & cLng(Request.QueryString("MEMBER_ID")) & " "
			strSql3 = strSql3 & " OR R.R_AUTHOR = " & cLng(Request.QueryString("MEMBER_ID")) & ") "
		end if
		if strPrivateForums = "1" and mLev < 4 then
			strSql3 = strSql3 & " AND F.FORUM_ID IN (" & allAllowedForums & ")"
		end if
		strSql3 = strSql3 & " AND F.F_TYPE = 0"

		strSql4 = " ORDER BY C.CAT_ORDER, C.CAT_NAME, F.F_ORDER, F.F_SUBJECT, T.T_LAST_POST DESC"

		mypage = request("whichpage")
		if ((Trim(mypage) = "") or (IsNumeric(mypage) = False)) then mypage = 1
		mypage = cLng(mypage)

		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(DISTINCT T.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

		if strModeration = "1" and mLev > 2 then
			UnModeratedPosts = CheckForUnmoderatedPosts("BOARD", 0, 0, 0)
			UnModeratedFPosts = 0
		end if

		Response.Write	"      <table border=""0"" width=""100%"" align=""center"">" & vbNewline & _
				"        <tr>" & vbNewline & _
				"          <td width=""33%"" align=""left"" nowrap><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine & _
				"          " & getCurrentIcon(strIconFolderOpen,"","align=""absmiddle""") & " <a href=""default.asp"">Tous Les Forums</a><br />" & vbNewline
		Response.Write	"          " & getCurrentIcon(strIconBar,"","align=""absmiddle""") & getCurrentIcon(strIconFolderOpen,"","align=""absmiddle""") & " <a href=""search.asp"">Recherche Dans Formulaire</a><br />" & vbNewLine
		if Request.Form("Search") <> "" then
			Response.Write	"          " & getCurrentIcon(strIconBlank,"","align=""absmiddle""") & getCurrentIcon(strIconBar,"","align=""absmiddle""") & getCurrentIcon(strIconFolderOpenTopic,"","align=""absmiddle""") & " Résultats de la Recherche Pour: " & chkString(Request.Form("Search"),"display")
		elseif Request.QueryString("MEMBER_ID") <> "" then
			Response.Write	"          " & getCurrentIcon(strIconBlank,"","align=""absmiddle""") & getCurrentIcon(strIconBar,"","align=""absmiddle""") & getCurrentIcon(strIconFolderOpenTopic,"","align=""absmiddle""") & " Résultats de la recherche pour: Tous les Sujets non-archivées qui contiennent les messages de " & getMemberName(cLng(Request.QueryString("MEMBER_ID")))
		end if
		Response.Write	"</font></td>" & vbNewline & _
				"        </tr>" & vbNewline
		if maxpages > 1 then
			Response.Write	"        <tr align=""right"">" & vbNewLine
			Call DropDownPaging(1)
			Response.Write	"        </tr>" & vbNewLine
		end if
		Response.Write	"      </table>" & vbNewLine

		Response.Write	"      <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 & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """> </font></b></td>" & vbNewLine & _
				"                <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Sujet</font></b></td>" & vbNewLine & _
				"                <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Auteur</font></b></td>" & vbNewLine & _
				"                <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Réponses</font></b></td>" & vbNewLine & _
				"                <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Lu</font></b></td>" & vbNewLine & _
				"                <td align=""center"" bgcolor=""" & strHeadCellColor & """><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Dernier Message</font></b></td>" & vbNewLine & _
				"              </tr>" & vbNewLine
		if iTopicCount = "" then '## No Search Results
			Response.Write	"              <tr>" & vbNewLine & _
					"                <td bgcolor=""" & strForumCellColor & """ colspan=""6""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><b>Aucuns Trouvés</b></font></td>" & vbNewLine & _
					"              </tr>" & vbNewLine
		else 
			cCAT_STATUS = 0
			cCAT_SUBSCRIPTION = 1
			cCAT_NAME = 2
			fFORUM_ID = 5
			fF_SUBJECT = 6
			fCAT_ID = 7
			fF_SUBSCRIPTION = 8
			fF_STATUS = 9
			tTOPIC_ID = 10
			tT_AUTHOR = 11
			tT_SUBJECT = 12
			tT_STATUS = 13
			tT_LAST_POST = 14
			tT_LAST_POST_AUTHOR = 15
			tT_LAST_POST_REPLY_ID = 16
			tT_REPLIES = 17
			tT_UREPLIES = 18
			tT_VIEW_COUNT = 19
			mMEMBER_ID = 20
			mM_NAME = 21
			tLAST_POST_AUTHOR_NAME = 22
			fF_PRIVATEFORUMS = 23
			fF_PASSWORD_NEW = 24

			currForum = 0 
			currTopic = 0
			dim Cat_Status
			dim Cat_Subscription
			dim Forum_Status
			dim Forum_Subscription
			dim mdisplayed
			mdisplayed = 0
			rec = 1

			for iTopic = 0 to iTopicCount
				if (rec = strPageSize + 1) then exit for

				Cat_Status = arrTopicData(cCAT_STATUS, iTopic)
				Cat_Subscription = arrTopicData(cCAT_SUBSCRIPTION, iTopic)
				Cat_Name = arrTopicData(cCAT_NAME, iTopic)
				Forum_ID = arrTopicData(fFORUM_ID, iTopic)
				Forum_Subject = arrTopicData(fF_SUBJECT, iTopic)
				Forum_Cat_ID = arrTopicData(fCAT_ID, iTopic)
				Forum_Subscription = arrTopicData(fF_SUBSCRIPTION, iTopic)
				Forum_Status = arrTopicData(fF_STATUS, iTopic)
				Topic_ID = arrTopicData(tTOPIC_ID, iTopic)
				Topic_Author = arrTopicData(tT_AUTHOR, iTopic)
				Topic_Subject = arrTopicData(tT_SUBJECT, iTopic)
				Topic_Status = arrTopicData(tT_STATUS, 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_Replies = arrTopicData(tT_REPLIES, iTopic)
				Topic_UReplies = arrTopicData(tT_UREPLIES, iTopic)
				Topic_ViewCount = arrTopicData(tT_VIEW_COUNT, iTopic)
				Topic_MemberID = arrTopicData(mMEMBER_ID, iTopic)
				Topic_MemberName = arrTopicData(mM_NAME, iTopic)
				Topic_LastPostAuthorName = arrTopicData(tLAST_POST_AUTHOR_NAME, iTopic)
				Forum_PrivateForums = arrTopicData(fF_PRIVATEFORUMS, iTopic)
				Forum_FPasswordNew = arrTopicData(fF_PASSWORD_NEW, iTopic)

				if mLev = 4 then
					AdminAllowed = 1
				else
				    	AdminAllowed = 0
				end if
				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
				if (currForum <> Forum_ID) and (currTopic <> Topic_ID) then 
					Response.Write	"              <tr>" & vbNewLine & _
							"                <td height=""20"" colspan=""6"" bgcolor=""" & strCategoryCellColor & """ valign=""middle""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strCategoryFontColor & """><a href=""default.asp?CAT_ID=" & Forum_Cat_ID & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strCategoryFontColor & """><b>" & ChkString(Cat_Name,"display") & "</b></font></a> / <a href=""forum.asp?FORUM_ID=" & Forum_ID & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strCategoryFontColor & """><b>" & ChkString(Forum_Subject,"display") & "</b></font></a></font></td>" & vbNewline & _
							"              </tr>" & vbNewLine
					currForum = Forum_ID
				end if 
				if currTopic <> Topic_ID then
					Response.Write	"              <tr>" & vbNewline
					if Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0 then 
						' DEM --> Added if statement to display topic status properly
						if Topic_Status = 2 then
							UnApprovedFound = "Y"
							Response.Write	"                <td bgcolor=""" & strForumCellColor & """ align=""center""><a href=""topic.asp?TOPIC_ID=" & Topic_ID & SearchLink & """>" & getCurrentIcon(strIconFolderUnmoderated,"Sujet Non-Modéré","hspace=""0""") & "</a></td>" & vbNewline
						elseif Topic_Status = 3 then
							HeldFound = "Y"
							Response.Write	"                <td bgcolor=""" & strForumCellColor & """ align=""center""><a href=""topic.asp?TOPIC_ID=" & Topic_ID & SearchLink & """>" & getCurrentIcon(strIconFolderHold,"Sujet En-Attente","hspace=""0""") & "</a></td>" & vbNewline
						else
							Response.Write	"                <td bgcolor=""" & strForumCellColor & """ align=""center""><a href=""topic.asp?TOPIC_ID=" & Topic_ID & SearchLink & """>" & ChkIsNew(Topic_LastPost) & "</a></td>" & vbNewline
						end if
					else 
						if Cat_Status = 0 then 
							strAltText = "Catégorie Verrouillée"
						elseif Forum_Status = 0 then 
							strAltText = "Forum Verrouillé"
						else
							strAltText = "Sujet Verrouillé"
						end if 
						Response.Write	"                <td bgcolor=""" & strForumCellColor & """ align=""center""><a href=""topic.asp?TOPIC_ID=" & Topic_ID & SearchLink & """>" & getCurrentIcon(strIconFolderLocked,strAltText,"hspace=""0""") & "</a></td>" & vbNewline
					end if
					Response.Write	"                <td bgcolor=""" & strForumCellColor & """><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>"
					Response.Write	"<span class=""spnMessageText""><a href=""topic.asp?TOPIC_ID=" & Topic_ID & SearchLink & """>" & ChkString(left(Topic_Subject, 50),"display") & "</a></span> </font>" & vbNewLine
					if strShowPaging = "1" then
						TopicPaging()
					end if
					Response.Write	"                </td>" & vbNewLine & _
							"                <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """><span class=""spnMessageText"">" & profileLink(chkString(Topic_MemberName,"display"),Topic_MemberID) & "</span></font></td>" & vbNewLine & _
							"                <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """>" & Topic_Replies & "</font></td>" & vbNewLine & _
							"                <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """>" & Topic_ViewCount & "</font></td>" & vbNewLine
					if IsNull(Topic_LastPostAuthor) then
						strLastAuthor = ""
					else
						strLastAuthor = "<br />par: <span class=""spnMessageText"">" & profileLink(Topic_LastPostAuthorName,Topic_LastPostAuthor) & "</span>"
						if (strJumpLastPost = "1" and ArchiveView = "") then strLastAuthor = strLastAuthor & " " & DoLastPostLink
					end if
					Response.Write	"                <td bgcolor=""" & strForumCellColor & """ valign=""middle"" align=""center"" nowrap><font face=""" & strDefaultFontFace & """ color=""" & strForumFontColor & """ size=""" & strFooterFontSize & """><b>" & ChkDate(Topic_LastPost, "</b> " ,true) & strLastAuthor & "</font></td>" & vbNewLine
					Response.Write	"              </tr>" & vbNewLine
					currTopic = Topic_ID
					rec = rec + 1 
				end if 
				mdisplayed = mdisplayed + 1
			next
			if mdisplayed = 0 then
				Response.Write	"              <tr>" & vbNewLine & _
						"                <td bgcolor=""" & strForumCellColor & """ colspan=""6""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><b>Aucuns Trouvés</b></font></td>" & vbNewLine & _
						"              </tr>" & vbNewLine
			end if
		end if 
		Response.Write	"            </table>" & vbNewLine & _
				"          </td>" & vbNewLine & _
				"        </tr>" & vbNewLine
		Response.Write	"      </table>" & vbNewLine

		if maxpages > 1 then
			Response.Write	"      <table border=""0"" width=""100%"" align=""center"">" & vbNewline & _
					"        <tr>" & vbNewLine
			Call DropDownPaging(2)
			Response.Write	"        </tr>" & vbNewLine & _
					"      </table>" & vbNewLine
		end if

		Response.Write	"      <table width=""100%"" align=""center"" border=""0"">" & vbNewLine & _
				"        <tr>" & vbNewLine & _
				"          <td align=""left"" valign=""top"">" & vbNewLine & _
				"            <table>" & vbNewLine & _
				"              <tr>" & vbNewLine & _
				"                <td nowrap>" & vbNewLine & _
				"                <p><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>" & vbNewLine & _
				"                " & getCurrentIcon(strIconFolderNew,"Nouveaux Messages","align=""absmiddle""") & " Contient de nouveaux messages depuis votre dernière connexion.<br />" & vbNewLine & _
				"                " & getCurrentIcon(strIconFolder,"Anciens Messages","align=""absmiddle""") & " Anciens Messages."
		if lcase(strHotTopic) = "1" then Response.Write	(" (" & getCurrentIcon(strIconFolderHot,"Sujet Brulant","align=""absmiddle""") & " " & intHotTopicNum & " réponses ou plus.)<br />" & vbNewLine)
		Response.Write	"                " & getCurrentIcon(strIconFolderLocked,"Sujet Verrouillé","align=""absmiddle""") & " Sujet Verrouillé.<br />" & vbNewLine
		' DEM --> Start of Code added for moderation
		if HeldFound = "Y" then
			Response.Write "                " & getCurrentIcon(strIconFolderHold,"Sujet En-Attente","align=""absmiddle""") & " Sujet En-Attente.<br />" & vbNewline
		end if
		if UnApprovedFound = "Y" then
			Response.Write "                " & getCurrentIcon(strIconFolderUnmoderated,"Sujet Non-Modéré","align=""absmiddle""") & " Sujet Non-Modéré.<br />" & vbNewline
		end if
		' DEM --> End of Code added for moderation
		Response.Write	"                </font></p></td>" & vbNewLine & _
				"              </tr>" & vbNewLine & _
				"            </table>" & vbNewLine & _
				"          </td>" & vbNewLine & _
				"        </tr>" & vbNewLine & _
				"      </table>" & vbNewLine

	else
		Response.Write	"      <p align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strHeaderFontSize & """>Vous devez entrer des mots clés</font></p>" & vbNewLine & _
				"      <p align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><a href=""JavaScript:history.go(-1)"">Retour A La Page De Recherche</a></font></p>" & vbNewLine & _
				"      <meta http-equiv=""Refresh"" content=""2; URL=JavaScript:history.go(-1)"">" & vbNewLine
	end if
else
	strRqForumID = cLng(Request.QueryString("FORUM_ID"))

	Response.Write	"      <table border=""0"" width=""100%"" align=""center"">" & vbNewline & _
			"        <tr>" & vbNewline & _
			"          <td width=""33%"" align=""left"" nowrap><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine & _
			"          " & getCurrentIcon(strIconFolderOpen,"","align=""absmiddle""") & " <a href=""default.asp"">Tous Les Forums</a><br />" & vbNewline & _
			"          " & getCurrentIcon(strIconBar,"","align=""absmiddle""") & getCurrentIcon(strIconFolderOpen,"","align=""absmiddle""") & " Recherche Dans Formulaire</font></td>" & vbNewline & _
			"        </tr>" & vbNewline & _
			"      </table><br />" & vbNewLine

	Response.Write	"      <form action=""search.asp?mode=DoIt"" name=""SearchForm"" id=""SearchForm"" method=""post"">" & vbNewLine & _
			"      <table border=""0"" cellspacing=""0"" cellpadding=""0"" align=""center"">" & vbNewLine & _
			"        <tr>" & vbNewLine & _
			"          <td bgcolor=""" & strPopUpBorderColor & """>" & vbNewLine & _
			"            <table border=""0"" cellspacing=""1"" cellpadding=""1"">" & vbNewLine & _
			"              <tr>" & vbNewLine & _
			"                <td bgColor=""" & strPopUpTableColor & """ align=""right"" valign=""top""><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>Recherche De:</font></b></td>" & vbNewLine & _
			"                <td bgColor=""" & strPopUpTableColor & """ align=""left"" valign=""middle""><input type=""text"" name=""Search"" size=""40"" value=""" & trim(ChkString(Request.QueryString("Search"),"display")) & """><br />" & vbNewLine & _
			"                <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine
	'################# New Search Code #################################################
	Response.Write	"                <input type=""radio"" class=""radio"" name=""andor"" value=""3"">Contient la phrase exacte<br />" & vbNewLine
	'################# New Search Code #################################################
	Response.Write	"                <input type=""radio"" class=""radio"" name=""andor"" value=""1"" checked>Rechercher tous les mots<br />" & vbNewLine & _
			"                <input type=""radio"" class=""radio"" name=""andor"" value=""2"">N'importe quels mots</font></td>" & vbNewLine & _
			"              </tr>" & vbNewLine & _
			"              <tr>" & vbNewLine & _
			"                <td bgColor=""" & strPopUpTableColor & """ align=""right"" valign=""middle""><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>Recherche Dans Forum:</font></b></td>" & vbNewLine & _
			"                <td bgColor=""" & strPopUpTableColor & """ align=""left"" valign=""middle"">" & vbNewLine & _
			"                <select name=""Forum"" size=""1"">" & vbNewLine & _
			"                	<option value=""0"">Tous Les Forums</option>" & vbNewLine
	'## Forum_SQL
	strSql = "SELECT F.FORUM_ID, F.F_SUBJECT FROM " & strTablePrefix & "FORUM F, " & strTablePrefix & "CATEGORY C"
	strSql = strSql & " WHERE F_TYPE = " & 0
	if strPrivateForums = "1" and allAllowedForums <> "" and mLev < 4 then
		strSql = strSql & " AND F.FORUM_ID IN (" & allAllowedForums & ")"
	end if
	strSql = strSql & " AND C.CAT_ID = F.CAT_ID"
	strSql = strSql & " ORDER BY C.CAT_ORDER, C.CAT_NAME, F.F_ORDER, F.F_SUBJECT"

	set rs = Server.CreateObject("ADODB.Recordset")
	rs.open strSql, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText

	if rs.EOF then
		recForumCount = ""
	else
		allForumData = rs.GetRows(adGetRowsRest)
		recForumCount = UBound(allForumData,2)
		fFORUM_ID = 0
		fF_SUBJECT = 1
	end if

	rs.close
	set rs = nothing

	if recForumCount <> "" then
		for iForum = 0 to recForumCount
			ForumForumID = allForumData(fFORUM_ID, iForum)
			ForumSubject = allForumData(fF_SUBJECT, iForum)
			Response.Write	"                	<option value=""" & ForumForumID & """"
			if strRqForumID = ForumForumID then Response.Write(" selected")
			Response.Write	">" & ChkString(left(ForumSubject, 50),"display") & "</option>" & vbNewline
		next
	end if
	Response.Write	"                </select>" & vbNewLine & _
			"                </td>" & vbNewLine & _
			"              </tr>" & vbNewLine
	'################# New Search Code #################################################
	Response.Write	"              <tr>" & vbNewLine & _
			"                <td bgColor=""" & strPopUpTableColor & """ align=""right"" valign=""middle""><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>Recherche Dans:</font></b></td>" & vbNewLine & _
			"                <td bgColor=""" & strPopUpTableColor & """ align=""left"" valign=""middle"">" & vbNewLine & _
			"                <select name=""SearchMessage"">" & vbNewLine & _
			"                	<option value=""0"">Message Entier</option>" & vbNewLine & _
			"                	<option value=""1"">Objet Seulement</option>" & vbNewLine & _
			"                </select>" & vbNewLine
	if strArchiveState = "1" then Response.Write("                  <input type=""checkbox"" name=""ARCHIVE"" value=""true""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>Messages Archivés</font>" & vbNewLine)
	Response.Write	"                </td>" & vbNewLine & _
			"              </tr>" & vbNewLine
	'################# New Search Code #################################################
	Response.Write	"              <tr>" & vbNewLine & _
			"                <td bgColor=""" & strPopUpTableColor & """ align=""right"" valign=""middle""><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>Rechercher Par Date:</font></b></td>" & vbNewLine & _
			"                <td bgColor=""" & strPopUpTableColor & """ align=""left"" valign=""middle"">" & vbNewLine & _
			"                <select name=""SearchDate"">" & vbNewLine & _
			"			       	<option value=""0"">Toutes Dates</option>" & vbNewLine & _
			"                	<option value=""1"">Depuis Hier</option>" & vbNewLine & _
			"                	<option value=""2"">Depuis 2 Jours</option>" & vbNewLine & _
			"                	<option value=""5"">Depuis 5 Jours</option>" & vbNewLine & _
			"                	<option value=""7"">Depuis 1 Semaine</option>" & vbNewLine & _
			"                	<option value=""14"">Depuis 2 Semaines</option>" & vbNewLine & _
			"                	<option value=""30"">Depuis 1 Mois</option>" & vbNewLine & _
			"                	<option value=""60"">Depuis 2 Mois</option>" & vbNewLine & _
			"                	<option value=""120"">Depuis 4 Mois</option>" & vbNewLine & _
			"                	<option value=""365"">Depuis 1 An</option>" & vbNewLine & _
			"                </select>" & vbNewLine & _
			"                </td>" & vbNewLine & _
			"              </tr>" & vbNewLine & _
			"              <tr>" & vbNewLine & _
			"                <td bgColor=""" & strPopUpTableColor & """ align=""right"" valign=""middle""><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>Rechercher Par Membre:</font></b></td>" & vbNewLine
	if strUseMemberDropDownBox = 0 then
		Response.Write	"                <td bgColor=""" & strPopUpTableColor & """ align=""left"" valign=""middle""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><input name=""SearchMember"" value="""" size=""25""></font></td>" & vbNewLine
	else
		Response.Write	"                <td bgColor=""" & strPopUpTableColor & """ align=""left"" valign=""middle"">" & vbNewLine & _
				"                <select name=""SearchMember"">" & vbNewLine & _
				"                	<option value=""0"">Tous Les Membres</option>" & vbNewLine
		'## Forum_SQL
		strSql = "SELECT MEMBER_ID, M_NAME "
		strSql = strSql & " FROM " & strMemberTablePrefix & "MEMBERS"
		strSql = strSql & " WHERE M_STATUS = " & 1
		strSql = strSql & " ORDER BY M_NAME ASC;"
	
		set rs = Server.CreateObject("ADODB.Recordset")
		rs.open strSql, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText

		if rs.EOF then
			recMemberCount = ""
		else
			allMemberData = rs.GetRows(adGetRowsRest)
			recMemberCount = UBound(allMemberData,2)
			meMEMBER_ID = 0
			meM_NAME = 1
		end if

		rs.close
		set rs = nothing

		if recMemberCount <> "" then
			for iMember = 0 to recMemberCount
				MembersMemberID = allMemberData(meMEMBER_ID, iMember)
				MembersMemberName = allMemberData(meM_NAME, iMember)
				Response.Write	"                	<option value=""" & MembersMemberID & """>" & ChkString(MembersMemberName,"display") & "</option>" & vbNewline
			next
		end if
		Response.Write	"                </select>" & vbNewLine & _
				"                </td>" & vbNewLine
	end if
	Response.Write	"              </tr>" & vbNewLine & _
			"              <tr>" & vbNewLine & _
			"                <td bgColor=""" & strPopUpTableColor & """ align=""center"" valign=""middle"" colspan=""2""><input type=""submit"" value=""Rechercher""></td>" & vbNewLine & _
			"              </tr>" & vbNewLine & _
			"            </table>" & vbNewLine & _
			"          </td>" & vbNewLine & _
			"        </tr>" & vbNewLine & _
			"      </table>" & vbNewLine & _
			"    </form>" & vbNewLine
end if 
WriteFooter
Response.End
 
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)
		Response.Write("                    <tr>" & vbNewLine)
		Response.Write("                      <td valign=""bottom""><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>" & getCurrentIcon(strIconPosticon,"","") & "</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 & SearchLink
			ref = ref & """>" & counter & "</a></span></font></td>"
			Response.Write ref & vbNewLine
			if counter mod strPageNumberSize = 0 then
				Response.Write("                    </tr>" & vbNewLine)
				Response.Write("                    <tr>" & vbNewLine)
				Response.Write("                      <td> </td>" & vbNewLine)
			end if
		next				
	        Response.Write("                    </tr>" & vbNewLine)
	        Response.Write("                  </table>" & vbNewLine)
	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	"          <form name=""PageNum" & fnum & """ action=""search.asp?" & chkString(Request.QueryString,"SQLString") & """ method=""post"">" & vbNewLine
		Response.Write	"          <td><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine
		Response.Write	"          <input name=""Search"" type=""hidden"" value=""" & trim(chkString(Request.Form("Search"),"search")) & """>" & vbNewLine
		Response.Write	"          <input name=""andor"" type=""hidden"" value=""" & cLng(Request.Form("andor")) & """>" & vbNewLine
		Response.Write	"          <input name=""Forum"" type=""hidden"" value=""" & cLng(Request.Form("Forum")) & """>" & vbNewLine
		Response.Write	"          <input name=""SearchMessage"" type=""hidden"" value=""" & cLng(Request.Form("SearchMessage")) & """>" & vbNewLine
		if strArchiveState = "1" and ArchiveView = "true" then Response.Write("          <input name=""ARCHIVE"" type=""hidden"" value=""" & ArchiveView & """>" & vbNewLine)
		Response.Write	"          <input name=""SearchDate"" type=""hidden"" value=""" & cLng(Request.Form("SearchDate")) & """>" & vbNewLine
		if strUseMemberDropDownBox = 0 then
			Response.Write	"          <input name=""SearchMember"" type=""hidden"" value=""" & chkString(Request.Form("SearchMember"),"display") & """>" & vbNewLine
		else
			Response.Write	"          <input name=""SearchMember"" type=""hidden"" value=""" & cLng(Request.Form("SearchMember")) & """>" & vbNewLine
		end if
		if fnum = 1 then
			Response.Write("          <b>Page: </b><select name=""whichpage"" size=""1"" onchange=""ChangePage(" & fnum & ");"">" & vbNewLine)
		else
			Response.Write("          <b>Il y a  " & maxpages & " Pages de Recherches des Résultats: </b><select name=""whichpage"" size=""1"" onchange=""ChangePage(" & fnum & ");"">" & vbNewLine)
		end if
		for counter = 1 to maxpages
			if counter <> cLng(pge) then   
				Response.Write "          	<option value=""" & counter &  """>" & counter & "</option>" & vbNewLine
			else
				Response.Write "          	<option selected value=""" & counter &  """>" & counter & "</option>" & vbNewLine
			end if
		next
		if fnum = 1 then
			Response.Write("          </select><b> sur " & maxPages & "</b>" & vbNewLine)
		else
			Response.Write("          </select>" & vbNewLine)
		end if
		Response.Write("          </font></td>" & vbNewLine)
		Response.Write("          </form>" & vbNewLine)
	end if
end sub

Function DoLastPostLink()
	if Topic_Replies < 1 or Topic_LastPostReplyID = 0 then
		DoLastPostLink = "<a href=""topic.asp?" & ArchiveLink & "TOPIC_ID=" & Topic_ID & SearchLink & """>" & getCurrentIcon(strIconLastpost,"Allez Au Dernier Message","align=""absmiddle""") & "</a>"
	elseif Topic_LastPostReplyID <> 0 then
		PageLink = "whichpage=-1&"
		AnchorLink = "&REPLY_ID="
		DoLastPostLink = "<a href=""topic.asp?" & ArchiveLink & PageLink & "TOPIC_ID=" & Topic_ID & SearchLink & AnchorLink & Topic_LastPostReplyID & """>" & getCurrentIcon(strIconLastpost,"Allez Au Dernier Message","align=""absmiddle""") & "</a>"
	else
		DoLastPostLink = ""
	end if
end function
%>


Cordially,
Maxime

Taxation consists in so plucking the goose to get the most out of feathers with the least possible cries.(Jean-Baptiste Colbert)


Edited by - Maxime on 08 October 2014 23:41:14

Carefree
Advanced Member

Philippines
4207 Posts

Posted - 09 October 2014 :  09:03:39  Show Profile
Not exactly sure what you're saying. Please email me the question in French.
Go to Top of Page

HuwR
Forum Admin

United Kingdom
20584 Posts

Posted - 09 October 2014 :  13:38:34  Show Profile  Visit HuwR's Homepage
The search only shows links to posts, it does not show the content of the actual posts, is that what you require ?

MVC .net dev/test site | MVC .net running on Raspberry Pi
Go to Top of Page

Maxime
Average Member

France
521 Posts

Posted - 09 October 2014 :  18:19:18  Show Profile  Visit Maxime's Homepage
Here is a message containing a pdf file

Original post


Same message after the search function


I have the same results after the search for messages containing mp3 etc.

Cordially,
Maxime

Taxation consists in so plucking the goose to get the most out of feathers with the least possible cries.(Jean-Baptiste Colbert)

Go to Top of Page

Carefree
Advanced Member

Philippines
4207 Posts

Posted - 09 October 2014 :  21:36:08  Show Profile
I get it. When he searches, the search result displays do not incorporate the mods he has installed (e.g. pdf, mp3). Will have to take a look at search.asp.
Go to Top of Page

Maxime
Average Member

France
521 Posts

Posted - 10 October 2014 :  09:59:27  Show Profile  Visit Maxime's Homepage
Yes exactly Carefree

Cordially,
Maxime

Taxation consists in so plucking the goose to get the most out of feathers with the least possible cries.(Jean-Baptiste Colbert)

Go to Top of Page

HuwR
Forum Admin

United Kingdom
20584 Posts

Posted - 10 October 2014 :  12:34:24  Show Profile  Visit HuwR's Homepage
still don't follow, how can the search affect the display of a mod ? it just returns a set of links to topics

MVC .net dev/test site | MVC .net running on Raspberry Pi
Go to Top of Page

Carefree
Advanced Member

Philippines
4207 Posts

Posted - 10 October 2014 :  14:54:47  Show Profile
A few mods which changed how things were displayed in topic.asp are being broken by the search highlighting function. Not sure how yet, have to look at them.
Go to Top of Page

HuwR
Forum Admin

United Kingdom
20584 Posts

Posted - 10 October 2014 :  16:00:19  Show Profile  Visit HuwR's Homepage
are right the highlighting, it must be wrapping part of the mods tags especially if they are part of the search terms maybe.

if you put some random string of characters in the post and search for that, does it have the same problem ?

MVC .net dev/test site | MVC .net running on Raspberry Pi
Go to Top of Page

Maxime
Average Member

France
521 Posts

Posted - 10 October 2014 :  20:08:57  Show Profile  Visit Maxime's Homepage
Hello,

If this can help, I am attaching the file topic.asp

topic.asp

<%
'#################################################################################
'## Snitz Forums 2000 v3.4.07
'#################################################################################
'## Copyright (C) 2000-09 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
'##
'#################################################################################
%>
<!--#INCLUDE FILE="config.asp"-->
<%

if (Request.QueryString("TOPIC_ID") = "" or IsNumeric(Request.QueryString("TOPIC_ID")) = False) and Request.Form("Method_Type") <> "login" and Request.Form("Method_Type") <> "logout" then
	Response.Redirect "default.asp"
	Response.End
else
	Topic_ID = cLng(Request.QueryString("TOPIC_ID"))
end if 
Dim ArchiveView, ArchiveLink, CColor
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

%>
<!--#INCLUDE FILE="inc_sha256.asp"-->
<!--#INCLUDE FILE="inc_header.asp" -->
<!--#INCLUDE FILE="inc_func_secure.asp" -->
<!--#INCLUDE FILE="inc_func_member.asp" -->
<!--#INCLUDE FILE="inc_subscription.asp" -->
<!--#INCLUDE FILE="inc_moderation.asp" -->

<% 
'	##	Double Register Below
If strDoubleReg = "1" Then
	Response.Cookies ("forums").Path = strCookieURL
	Response.Cookies ("forums")("registered") = "yes"
	Response.Cookies ("forums").Expires = Date + 365
End If
'	##	Double Register Above
Response.Write	"    <script language=""JavaScript"" type=""text/javascript"">" & vbNewLine & _
		"    function ChangePage(fnum){" & vbNewLine & _
		"    	if (fnum == 1) {" & vbNewLine & _
		"    		document.PageNum1.submit();" & vbNewLine & _
		"    	}" & vbNewLine & _
		"    	else {" & vbNewLine & _
		"    		document.PageNum2.submit();" & vbNewLine & _
		"    	}" & vbNewLine & _
		"    }" & vbNewLine & _
		"    </script>" & vbNewLine

mypage = request("whichpage")
if ((Trim(mypage) = "") or (IsNumeric(mypage) = False)) then mypage = 1
mypage = cLng(mypage)

if Request("SearchTerms") <> "" then
	SearchLink = "&SearchTerms=" & Request("SearchTerms")
else
	SearchLink = ""
end if

if strSignatures = "1" and strDSignatures = "1" then
	if ViewSig(MemberID) <> "0" then
		CanShowSignature = 1
	end if
end if

'## Forum_SQL - Get original topic and check for the Category, Forum or Topic Status and existence
strSql = "SELECT M.M_NAME, M.M_RECEIVE_EMAIL, M.M_AIM, M.M_ICQ, M.M_MSN, M.M_SKYPE, M.M_YAHOO, M.M_PMRECEIVE" & _
	", M.M_TITLE, M.M_HOMEPAGE, M.MEMBER_ID, M.M_LEVEL, M.M_POSTS, M.M_COUNTRY, M.M_PHOTO_URL, M.M_AVATAR_URL" & _
	", T.T_DATE, T.T_SUBJECT, T.T_AUTHOR, T.TOPIC_ID, T.T_STATUS, T.T_LAST_EDIT" & _
	", T.T_LAST_EDITBY, T.T_LAST_POST, T.T_SIG, T.T_REPLIES" & _
	", C.CAT_STATUS, C.CAT_ID, C.CAT_NAME, C.CAT_SUBSCRIPTION, C.CAT_MODERATION" & _
	", F.F_STATUS, F.FORUM_ID, F.F_SUBSCRIPTION, F.F_SUBJECT, F.F_MODERATION, T.T_MESSAGE"
if CanShowSignature = 1 then
	strSql = strSql & ", M.M_SIG"
end if
strSql = strSql & " FROM " & strActivePrefix & "TOPICS T, " & strTablePrefix & "FORUM F, " & _ 
	strTablePrefix & "CATEGORY C, " & strMemberTablePrefix & "MEMBERS M " & _
	" WHERE T.TOPIC_ID = " & Topic_ID & _
	" AND F.FORUM_ID = T.FORUM_ID " & _
	" AND C.CAT_ID = T.CAT_ID " & _
	" AND M.MEMBER_ID = T.T_AUTHOR "

set rsTopic = Server.CreateObject("ADODB.Recordset")
rsTopic.open strSql, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText

if rsTopic.EOF then
	recTopicCount = ""
else
	recTopicCount = 1
	Member_Name = rsTopic("M_NAME")
	Member_ReceiveMail = rsTopic("M_RECEIVE_EMAIL")
	Member_AIM = rsTopic("M_AIM")
	Member_ICQ = rsTopic("M_ICQ")
	Member_MSN = rsTopic("M_MSN")
	Member_SKYPE = rsTopic("M_SKYPE")
	Member_YAHOO = rsTopic("M_YAHOO")
	Member_PM = rsTopic("M_PMRECEIVE")
	Member_Title = rsTopic("M_TITLE")
	Member_Homepage = rsTopic("M_HOMEPAGE")
	tMember_ID = rsTopic("MEMBER_ID")
	Member_Level = rsTopic("M_LEVEL")
	Member_Posts = rsTopic("M_POSTS")
	Member_Country = rsTopic("M_COUNTRY")
	Member_Photo = rsTopic("M_PHOTO_URL")
	Member_Avatar = rsTopic("M_AVATAR_URL")
	Topic_Date = rsTopic("T_DATE")
	Topic_Subject = rsTopic("T_SUBJECT")
	Topic_Author = rsTopic("T_AUTHOR")
	TopicID = rsTopic("TOPIC_ID")
	Topic_Status = rsTopic("T_STATUS")
	Topic_LastEdit = rsTopic("T_LAST_EDIT")
	Topic_LastEditby = rsTopic("T_LAST_EDITBY")
	Topic_LastPost = rsTopic("T_LAST_POST")
	Topic_Sig = rsTopic("T_SIG")
	Topic_Replies = rsTopic("T_REPLIES")
	Cat_Status = rsTopic("CAT_STATUS")
	Cat_ID = rsTopic("CAT_ID")
	Cat_Name = rsTopic("CAT_NAME")
	Cat_Subscription = rsTopic("CAT_SUBSCRIPTION")
	Cat_Moderation = rsTopic("CAT_MODERATION")
	Forum_Status = rsTopic("F_STATUS")
	Forum_ID = rsTopic("FORUM_ID")
	Forum_Subject = rsTopic("F_SUBJECT")
	Forum_Subscription = rsTopic("F_SUBSCRIPTION")
	Forum_Moderation = rsTopic("F_MODERATION")
	Topic_Message = rsTopic("T_MESSAGE")
	if CanShowSignature = 1 then
		Topic_MemberSig = trim(rsTopic("M_SIG"))
	end if
end if

rsTopic.close
set rsTopic = nothing

if recTopicCount = "" then
	if ArchiveView <> "true" then
		Response.Redirect("topic.asp?ARCHIVE=true&" & ChkString(Request.QueryString,"sqlstring"))
	else
		Response.Redirect("default.asp")
	end if
end if

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 strModeration > 0 and Cat_Moderation > 0 and Forum_Moderation > 0 and AdminAllowed = 0 then
        Moderation = "Y"
else
        Moderation = "N"
end if

if mypage = -1 then
	strSql = "SELECT REPLY_ID FROM " & strActivePrefix & "REPLY WHERE TOPIC_ID = " & Topic_ID & " "
	if AdminAllowed = 0 then
		strSql = strSql & " AND (R_STATUS < "
		if Moderation = "Y" then
			strSql = strSql & "2 "
		else
			strSql = strSql & "3 "
		end if
		strSql = strSql & "OR R_AUTHOR = " & MemberID & ") "
	end if
	strSql = strSql & "ORDER BY R_DATE ASC "

	set rsReplies = Server.CreateObject("ADODB.Recordset")
	if strDBType = "mysql" then
		rsReplies.open strSql, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText
	else
		rsReplies.open strSql, my_Conn, adOpenStatic, adLockReadOnly, adCmdText
	end if
	
	if not rsReplies.EOF then
		arrReplyData = rsReplies.GetRows(adGetRowsRest)
		iReplyCount = UBound(arrReplyData, 2)
		
		if Request.Querystring("REPLY_ID") <> "" and IsNumeric(Request.Querystring("REPLY_ID")) then
			LastPostReplyID = cLng(Request.Querystring("REPLY_ID"))
			for iReply = 0 to iReplyCount
				intReplyID = arrReplyData(0, iReply)
				if LastPostReplyID = intReplyID then
					intPageNumber = ((iReply+1)/strPageSize)
					exit for
				end if
			next
		else
			LastPostReplyID = cLng(arrReplyData(0, iReplyCount))
			intPageNumber = ((iReplyCount+1)/strPageSize)
		end if
		if intPageNumber > cLng(intPageNumber) then
			intPageNumber = cLng(intPageNumber) + 1
		end if
		strwhichpage = "whichpage=" & intPageNumber & "&"
	else
		strwhichpage = ""
	end if
	
	rsReplies.close
	set rsReplies = nothing
	my_Conn.close
	set my_Conn = nothing
	
	Response.Redirect "topic.asp?" & ArchiveLink & strwhichpage & "TOPIC_ID=" & Topic_ID & SearchLink & "#" & LastPostReplyID
	Response.End
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

if (Moderation = "Y" and Topic_Status > 1 and Topic_Author <> MemberID) then
	Response.write  "<p align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strHeaderFontSize & """><br />Voir sur ce sujet n'est pas autorisé jusqu'à ce qu'il ait été modéré.<br />S'il vous plaît réessayer plus tard</font></p>" & vbNewLine & _
			"<p align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strHeaderFontSize & """><a href=""JavaScript:history.go(-1)"">Retour</a></font></p><br />" & vbNewLine
	WriteFooter
	Response.end
else
	Response.Write	"    <script language=""JavaScript"" type=""text/javascript"">" & vbNewLine & _
			"    <!--" & vbNewLine & _
			"    function jumpTo(s) {if (s.selectedIndex != 0) location.href = s.options[s.selectedIndex].value;return 1;}" & vbNewLine & _
			"    // -->" & vbNewLine & _
			"    </script>" & vbNewLine

	'## Forum_SQL
	strSql = "SELECT M.M_NAME, M.M_RECEIVE_EMAIL, M.M_AIM, M.M_ICQ, M.M_MSN, M.M_SKYPE, M.M_YAHOO, M.M_PMRECEIVE"
	strSql = strSql & ", M.M_TITLE, M.MEMBER_ID, M.M_HOMEPAGE, M.M_LEVEL, M.M_POSTS, M.M_COUNTRY, M.M_PHOTO_URL, M.M_AVATAR_URL"
	strSql = strSql & ", R.REPLY_ID, R.FORUM_ID, R.R_AUTHOR, R.TOPIC_ID, R.R_MESSAGE, R.R_LAST_EDIT"
	strSql = strSql & ", R.R_LAST_EDITBY, R.R_SIG, R.R_STATUS, R.R_DATE"
	if CanShowSignature = 1 then
		strSql = strSql & ", M.M_SIG"
	end if
	strSql2 = " FROM " & strMemberTablePrefix & "MEMBERS M, " & strActivePrefix & "REPLY R "
	strSql3 = " WHERE M.MEMBER_ID = R.R_AUTHOR "
	strSql3 = strSql3 & " AND R.TOPIC_ID = " & Topic_ID & " "
		' DEM --> if not a Moderator, all unapproved posts should not be viewed.
		if AdminAllowed = 0 then
			strSql3 = strSql3 & " AND (R.R_STATUS < "
			if Moderation = "Y" then
				' Ignore unapproved/rejected posts
				strSql3 = strSql3 & "2"
			else
				' Ignore any previously rejected topic
				strSql3 = strSql3 & "3"
			end if
		strSql3 = strSql3 & " OR R.R_AUTHOR = " & MemberID & ")"
	end if
	strSql4 = " ORDER BY R.R_DATE ASC"

	if strDBType = "mysql" then 'MySql specific code
		if mypage > 1 then
 			intOffset = cLng((mypage-1) * strPageSize)
			strSql5 = " LIMIT " & intOffset & ", " & strPageSize & " "
		end if

		'## Forum_SQL - Get the total pagecount 
		strSql1 = "SELECT COUNT(R.TOPIC_ID) AS REPLYCOUNT "
		
		set rsCount = my_Conn.Execute(strSql1 & strSql2 & strSql3)
		iPageTotal = rsCount(0).value
		rsCount.close
		set rsCount = nothing

		if iPageTotal > 0 then
			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
			maxpages = 0
		end if
	
		if iPageTotal > 0 then
			set rsReplies = Server.CreateObject("ADODB.Recordset")
			rsReplies.Open strSql & strSql2 & strSql3 & strSql4 & strSql5, my_Conn, adOpenForwardOnly, adLockReadOnly, adCmdText
				arrReplyData = rsReplies.GetRows(intGetRows)
				iReplyCount = UBound(arrReplyData, 2)
			rsReplies.Close
			set rsReplies = nothing
		else
			iReplyCount = ""
		end if
		
	else 'end MySql specific code
	
		set rsReplies = Server.CreateObject("ADODB.Recordset")
		rsReplies.cachesize = strPageSize
		rsReplies.open strSql & strSql2 & strSql3 & strSql4, my_Conn, adOpenStatic, adLockReadOnly, adCmdText

			if not (rsReplies.EOF or rsReplies.BOF) then
				rsReplies.pagesize = strPageSize
				rsReplies.absolutepage = mypage '**
				maxpages = cLng(rsReplies.pagecount)
				if maxpages >= mypage then
					arrReplyData = rsReplies.GetRows(strPageSize)
					iReplyCount = UBound(arrReplyData, 2)
				else
					iReplyCount = ""
				end if
			else  '## No replies found in DB
				iReplyCount = ""
			end if

		rsReplies.Close
		set rsReplies = nothing
	end if

	Response.Write	"      <table border=""0"" width=""100%"">" & vbNewLine & _
			"        <tr>" & vbNewLine & _
			"          <td width=""50%"" align=""left"" nowrap><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine & _
			"          " & getCurrentIcon(strIconFolderOpen,"","align=""absmiddle""") & " <a href=""default.asp"">Tous Les Forums</a><br />" & 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	" <a href=""default.asp?CAT_ID=" & Cat_ID & """>" & ChkString(Cat_Name,"display") & "</a><br />" & vbNewLine & _
			"          " & getCurrentIcon(strIconBlank,"","align=""absmiddle""") & getCurrentIcon(strIconBar,"","align=""absmiddle""")
	if ArchiveView = "true" then
		Response.Write	getCurrentIcon(strIconFolderArchived,"","align=""absmiddle""")
	else
		if Forum_Status <> 0 and Cat_Status <> 0 then
			Response.Write	getCurrentIcon(strIconFolderOpen,"","align=""absmiddle""")
		else
			Response.Write	getCurrentIcon(strIconFolderClosed,"","align=""absmiddle""")
		end if
	end if
	Response.Write	" <a href=""forum.asp?" & ArchiveLink & "FORUM_ID=" & Forum_ID & """>" & ChkString(Forum_Subject,"display") & "</a><br />" & vbNewLine
	if ArchiveView = "true" then
		Response.Write	"          " & getCurrentIcon(strIconBlank,"","align=""absmiddle""") & getCurrentIcon(strIconBlank,"","align=""absmiddle""") & getCurrentIcon(strIconBar,"","align=""absmiddle""") & getCurrentIcon(strIconFolderArchived,"","align=""absmiddle""") & " "
	elseif Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0 then
		Response.Write	"          " & getCurrentIcon(strIconBlank,"","align=""absmiddle""") & getCurrentIcon(strIconBlank,"","align=""absmiddle""") & getCurrentIcon(strIconBar,"","align=""absmiddle""") & getCurrentIcon(strIconFolderOpenTopic,"","align=""absmiddle""") & " "
	else
		Response.Write	"          " & getCurrentIcon(strIconBlank,"","align=""absmiddle""") & getCurrentIcon(strIconBlank,"","align=""absmiddle""") & getCurrentIcon(strIconBar,"","align=""absmiddle""") & getCurrentIcon(strIconFolderClosedTopic,"","align=""absmiddle""") & " "
	end if
	if Request.QueryString("SearchTerms") <> "" then
		Response.Write	SearchHiLite(ChkString(Topic_Subject,"title"))
	else
		Response.Write	ChkString(Topic_Subject,"title")
	end if
	Response.Write	"</font></td>" & vbNewLine & _
			"          <td align=""center"" width=""50%"">" & vbNewLine
	call PostingOptions()
	Response.Write	"</td>" & vbNewLine & _
			"        </tr>" & vbNewLine & _
			"      </table>" & vbNewLine & _
			"    </td>" & vbNewLine & _
			"  </tr>" & vbNewLine & _
			"</table>" & vbNewLine
	if maxpages > 1 then
		Response.Write	"<table align=""center"" border=""0"" cellPadding=""0"" cellSpacing=""1"" width=""95%"">" & vbNewLine & _
				"  <tr>" & vbNewLine & _
				"    <td align=""right"" valign=""top""><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>"
		if mypage > 1 then Response.Write("<a href=""topic.asp?" & ArchiveLink & "TOPIC_ID=" & Topic_ID & "&whichpage=" & mypage-1 & SearchLink & """ title=""Allez à la page précédente dans ce sujet""" & dWStatus("Allez à la page précédente dans ce sujet") & ">Page Précédente</a>")
		'if mypage > 1 then Response.Write("<a href=""javascript: onclick=document.PageNum1.whichpage.value=" & mypage-1 & ";document.PageNum1.submit();"" title=""Allez à la page précédente dans ce sujet""" & dWStatus("Allez à la page précédente dans ce sujet") & ">Page Précédente</a>")
		if mypage > 1 and mypage < maxpages then Response.Write(" | ")
		if mypage < maxpages then Response.Write("<a href=""topic.asp?" & ArchiveLink & "TOPIC_ID=" & Topic_ID & "&whichpage=" & mypage+1 & SearchLink & """ title=""Allez à la page suivante de ce sujet""" & dWStatus("Allez à la page suivante de ce sujet") & ">Page Suivante</a>")
		'if mypage < maxpages then Response.Write("<a href=""javascript: onclick=document.PageNum1.whichpage.value=" & mypage+1 & ";document.PageNum1.submit();"" title=""Allez à la page suivante de ce sujet""" & dWStatus("Allez à la page suivante de ce sujet") & ">Page Suivante</a>")
		Response.Write	"</td>" & vbNewLine & _
			"  </tr>" & vbNewLine & _
			"</table>" & vbNewLine
	end if
	Response.Write	"<table align=""center"" border=""0"" cellPadding=""0"" cellSpacing=""0"" width=""95%"">" & vbNewLine & _
			"  <tr>" & vbNewLine & _
			"    <td>" & 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 & """ width=""" & strTopicWidthLeft & """"
	if lcase(strTopicNoWrapLeft) = "1" then Response.Write(" nowrap")
	Response.Write	"><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>Auteur</font></b></td>" & vbNewLine & _
			"                <td align=""center"" bgcolor=""" & strHeadCellColor & """ width=""" & strTopicWidthRight & """"
	if lcase(strTopicNoWrapRight) = "1" then Response.Write(" nowrap")
	Response.Write	"><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>" & vbNewLine
	if strShowTopicNav = "1" then
		Call Topic_nav()
	else
		Response.Write("Topic")
	end if
	Response.Write	"</font></b></td>" & vbNewLine
	if (AdminAllowed = 1) then
		if maxpages > 1 then
			Call DropDownPaging(1)
			Response.Write	"                <td align=""right"" bgcolor=""" & strHeadCellColor & """ nowrap>" & vbNewLine
			call AdminOptions()
			Response.Write	"                </td>" & vbNewLine
		else
			Response.Write	"                <td align=""right"" bgcolor=""" & strHeadCellColor & """ nowrap>" & vbNewLine
			call AdminOptions()
			Response.Write	"                </td>" & vbNewLine
		end if
	else
		if maxpages > 1 then
			Call DropDownPaging(1)
		else
	        	Response.Write	"                <td align=""right"" bgcolor=""" & strHeadCellColor & """ nowrap><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """> </font></td>" & vbNewLine
	 	end if
	end if
	Response.Write	"              </tr>" & vbNewLine
 
	if mypage = 1 then 
		Call GetFirst() 
	end if
	
	'## Forum_SQL
	strSql = "UPDATE " & strActivePrefix & "TOPICS "
	strSql = strSql & " SET T_VIEW_COUNT = (T_VIEW_COUNT + 1) "
	strSql = strSql & " WHERE (TOPIC_ID = " & Topic_ID & ")"

	my_conn.Execute (strSql),,adCmdText + adExecuteNoRecords
 
	if iReplyCount = "" then  '## No replies found in DB
		' Nothing
	else
		intI = 0 
	
		rM_NAME = 0
		rM_RECEIVE_EMAIL = 1
		rM_AIM = 2
		rM_ICQ = 3
		rM_MSN = 4
		rM_SKYPE = 5
		rM_YAHOO = 6
		rM_PM = 7
		rM_TITLE = 8
		rMEMBER_ID = 9
		rM_HOMEPAGE = 10
		rM_LEVEL = 11
		rM_POSTS = 12
		rM_COUNTRY = 13
		rM_Photo = 14
		rM_Avatar = 15
		rREPLY_ID = 16
		rFORUM_ID = 17
		rR_AUTHOR = 18
		rTOPIC_ID = 19
		rR_MESSAGE = 20
		rR_LAST_EDIT = 21
		rR_LAST_EDITBY = 22
		rR_SIG = 23
		rR_STATUS = 24
		rR_DATE = 25
		if CanShowSignature = 1 then
			rM_SIG = 26
		end if
		
		for iForum = 0 to iReplyCount

			Reply_MemberName = arrReplyData(rM_NAME, iForum)
			Reply_MemberReceiveEmail = arrReplyData(rM_RECEIVE_EMAIL, iForum)
			Reply_MemberAIM = arrReplyData(rM_AIM, iForum)
			Reply_MemberICQ = arrReplyData(rM_ICQ, iForum)
			Reply_MemberMSN = arrReplyData(rM_MSN, iForum)
			Reply_MemberSKYPE = arrReplyData(rM_SKYPE, iForum)
			Reply_MemberYAHOO = arrReplyData(rM_YAHOO, iForum)
			Reply_MemberPM = arrReplyData(rM_PM, iForum)
			Reply_MemberTitle = arrReplyData(rM_TITLE, iForum)
			Reply_MemberID = arrReplyData(rMEMBER_ID, iForum)
			Reply_MemberHomepage = arrReplyData(rM_HOMEPAGE, iForum)
			Reply_MemberLevel = arrReplyData(rM_LEVEL, iForum)
			Reply_MemberPosts = arrReplyData(rM_POSTS, iForum)
			Reply_MemberCountry = arrReplyData(rM_COUNTRY, iForum)
			Reply_MemberPhoto = arrReplyData(rM_PHOTO, iForum)
			Reply_MemberAvatar = arrReplyData(rM_Avatar, iForum)
			Reply_ReplyID = arrReplyData(rREPLY_ID, iForum)
			Reply_ForumID = arrReplyData(rFORUM_ID, iForum)
			Reply_Author = arrReplyData(rR_AUTHOR, iForum)
			Reply_TopicID = arrReplyData(rTOPIC_ID, iForum)
			Reply_Content = arrReplyData(rR_MESSAGE, iForum)
			Reply_LastEdit = arrReplyData(rR_LAST_EDIT, iForum)
			Reply_LastEditBy = arrReplyData(rR_LAST_EDITBY, iForum)
			Reply_Sig = arrReplyData(rR_SIG, iForum)
			Reply_Status = arrReplyData(rR_STATUS, iForum)
			Reply_Date = arrReplyData(rR_DATE, iForum)
			if CanShowSignature = 1 then
				Reply_MemberSig = trim(arrReplyData(rM_SIG, iForum))
			end if

			if intI = 0 then 
				CColor = strAltForumCellColor
			else
				CColor = strForumCellColor
			end if

			Response.Write	"              <tr>" & vbNewLine & _
					"                <td bgcolor=""" & CColor & """ valign=""top"" width=""" & strTopicWidthLeft & """"
			if lcase(strTopicNoWrapLeft) = "1" then Response.Write(" nowrap")
			Response.Write	">" & vbNewLine & _
					"                <p><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><b><span class=""spnMessageText"">" & profileLink(ChkString(Reply_MemberName,"display"),Reply_Author) & "</span></b></font><br />" & vbNewLine
			if strShowRank = 1 or strShowRank = 3 then
				Response.Write	"                <font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """><small>" & ChkString(getMember_Level(Reply_MemberTitle, Reply_MemberLevel, Reply_MemberPosts),"display") & "</small></font><br />" & vbNewLine
			end if
			if strShowRank = 2 or strShowRank = 3 then
				Response.Write	"                " & getStar_Level(Reply_MemberLevel, Reply_MemberPosts) & "<br />" & vbNewLine
			end if
		 	Response.Write	"                </p>" & vbNewLine & _
					"                <p>" & vbNewLine
			If Reply_MemberPhoto > "" Then
				Response.Write "<table width=""" & intAvatarWidth & """ height= """ & intAvatarHeight & """ cellspacing=""0"" cellpadding=""0"" border=""0"" style="" background-image: url('" & Reply_MemberPhoto & "');background-repeat: no-repeat; background-position: center;"">" & vbNewLine & _
					"	<tr>" & vbNewLine & _
					"			<td align=""center""><img src=""" & strImageURL & "noavatar.gif"" width=""96"" height=""96"" border=""0""></td>" & vbNewLine & _
					"		</tr>" & vbNewLine & _
					"	</table>" & vbNewLine
			end if	
'	##### Avatar Mod #####
			if Reply_MemberAvatar="1" then Reply_MemberAvatar="noavatar.gif"
			if Reply_MemberAvatar <> "noavatar.gif" then
				Response.Write "<table width=""" & intAvatarWidth & """ height= """ & intAvatarHeight & """ cellspacing=""0"" cellpadding=""0"" border=""0"" style="" background-image: url('" & Reply_MemberAvatar & "');background-repeat: no-repeat; background-position: center;"">" & vbNewLine & _
					"	<tr>" & vbNewLine & _
					"			<td align=""center""><img src=""" & strImageURL & "noavatar.gif"" width=""96"" height=""96"" border=""0""></td>" & vbNewLine & _
					"		</tr>" & vbNewLine & _
					"	</table>" & vbNewLine
			end if
'	### Avatar Mod End ###
			if strCountry = "1" and trim(Reply_MemberCountry) <> "" then
				Response.Write	"                <font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """><small>" & Reply_MemberCountry & "</small></font><br /><img src=""" & strImageURL & Reply_MemberCountry & ".gif""><br />" & vbNewLine
			end if
			Response.Write	"                <font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """><small>" & Reply_MemberPosts & " Messages</small></font></p></td>" & vbNewLine & _
					"                <td bgcolor=""" & CColor & """ height=""100%"" width=""" & strTopicWidthRight & """"
			if lcase(strTopicNoWrapRight) = "1" then Response.Write(" nowrap")
			if (AdminAllowed = 1) and (maxpages > 1) then
				Response.Write	(" colspan=""3"" ")
			else
				Response.Write	(" colspan=""2"" ")
			end if
			Response.Write	"valign=""top""><a name=""" & Reply_ReplyID & """></a>" & vbNewLine & _
					"                  <table width=""100%"" height=""100%"" border=""0"" cellspacing=""0"" cellpadding=""0"">" & vbNewLine & _
					"                    <tr>" & vbNewLine & _
					"                      <td valign=""top"">" & vbNewLine
			' DEM --> Start of Code altered for moderation
			if Reply_Status < 2 then
				Response.Write  "                      " & getCurrentIcon(strIconPosticon,"","hspace=""3""") & "<font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize  & """>Mis le - " & ChkDate(Reply_Date, " : " ,true) & "</font>" & vbNewline
			elseif Reply_Status = 2 then
				Response.Write  "                      <font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize  & """>NON MODERE!!!</font>" & vbNewline
			elseif Reply_Status = 3 then
				Response.Write  "                      " & getCurrentIcon(strIconPosticonHold,"","hspace=""3""") & "<font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize  & """>EN ATTENTE</font>" & vbNewline
			end if
			' DEM --> End of Code added for moderation.
			Response.Write	"                       " & profileLink(getCurrentIcon(strIconProfile,"Aperçu Profil","align=""absmiddle"" hspace=""6"""),Reply_MemberID) & vbNewLine
			if mLev > 2 or Reply_MemberReceiveEmail = "1" then
				if (mlev <> 0) or (mlev = 0 and  strLogonForMail <> "1") then
					Response.Write	"                       <a href=""JavaScript:openWindow('pop_mail.asp?id=" & Reply_MemberID & "')"">" & getCurrentIcon(strIconEmail," Envoyer Un Email","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
				end if
			end if
			if strHomepage = "1" then
				if Reply_MemberHomepage <> " " then
					Response.Write	"                       <a href=""" & Reply_MemberHomepage & """ target=""_blank"">" & getCurrentIcon(strIconHomepage,"Allez à " & ChkString(Reply_MemberName,"display") & "  Sur Son Site Web","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
				end if
			end if
			if (AdminAllowed = 1 or Reply_MemberID = MemberID) then
				if (Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0) or (AdminAllowed = 1) then
					Response.Write	"                       <a href=""post.asp?" & ArchiveLink & "method=Edit&REPLY_ID=" & Reply_ReplyID & "&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconEditTopic,"Editer Reponse","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
				end if
			end if
			if (strAIM = "1") then
				if Trim(Reply_MemberAIM) <> "" then
					Response.Write	"                       <a href=""JavaScript:openWindow('pop_messengers.asp?mode=AIM&ID=" & Reply_MemberID & "')"">" & getCurrentIcon(strIconAIM,"Envoyer " & ChkString(Reply_MemberName,"display") & " à AOL message","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
				end if
			end if
			if strICQ = "1" then
				if Trim(Reply_MemberICQ) <> "" then
					Response.Write	"                       <a href=""JavaScript:openWindow6('pop_messengers.asp?mode=ICQ&ID=" & Reply_MemberID & "')"">" & getCurrentIcon(strIconICQ,"Envoyer " & ChkString(Reply_MemberName,"display") & " à ICQ Message","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
				end if
			end if
			if (strMSN = "1") then
				if Trim(Reply_MemberMSN) <> "" then
					Response.Write	"                       <a href=""JavaScript:openWindow('pop_messengers.asp?mode=MSN&ID=" & Reply_MemberID & "')"">" & getCurrentIcon(strIconMSNM,"Cliquez pour voir " & ChkString(Reply_MemberName,"display") & " Adresse MSN Messenger","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
				end if
			end if
			if strSKYPE = "1" then
				if Trim(Reply_MemberSKYPE) <> "" then
					Response.Write	"                       <a href=""JavaScript:openWindow('pop_messengers.asp?mode=SKYPE&ID=" & Reply_MemberID & "')"">" & getCurrentIcon(strIconSKYPE,"Afficher l'adresse téléphone Skype " & ChkString(Reply_MemberName,"display") & "","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
				end if
			end if
			if strYAHOO = "1" then
				if Trim(Reply_MemberYAHOO) <> "" then
					Response.Write	"                       <a href=""http://edit.yahoo.com/config/send_webmesg?.target=" & ChkString(Reply_MemberYAHOO, "urlpath") & "&.src=pg"" target=""_blank"">" & getCurrentIcon(strIconYahoo,"Send " & ChkString(Reply_MemberName,"display") & " à Yahoo! Message","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
				end if
			end if
				If (Reply_MemberPM = "1" and strPMStatus = "1") Then
				if Trim(Reply_MemberPM) <> "" then
					Response.Write	"                <a href=""privatesend.asp?method=Topic&mname=" & ChkString(Reply_MemberName,"display") & """>" & getCurrentIcon(strIconPmprivatemessage,"Envoyer à " & ChkString(Reply_MemberName,"display") & " Un Message Privé","align=""absmiddle"" hspace=""0""") & "</a>" & vbNewLine
				End If
			End IF
			if ((Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status = 1) or (AdminAllowed = 1 and Topic_Status <= 1)) and ArchiveView = "" then
				Response.Write	"                       <a href=""post.asp?method=ReplyQuote&REPLY_ID=" & Reply_ReplyID & "&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconReplyTopic,"Réponse avec Citation","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
			end if
			if (strIPLogging = "1") then
				if (AdminAllowed = 1) then
					Response.Write	"                       <a href=""JavaScript:openWindow('pop_viewip.asp?" & ArchiveLink & "mode=getIP&REPLY_ID=" & Reply_ReplyID & "&FORUM_ID=" & Forum_ID & "')"">" & getCurrentIcon(strIconIP,"Voir Adresse IP de l'Utilisateur","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
				end if
			end if
			if (AdminAllowed = 1 or Reply_MemberID = MemberID) then
				if (Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0) or (AdminAllowed = 1) then
					Response.Write	"                       <a href=""JavaScript:openWindow('pop_delete.asp?" & ArchiveLink & "mode=Reply&REPLY_ID=" & Reply_ReplyID & "&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "')"">" & getCurrentIcon(strIconDeleteReply,"Supprimer Réponse","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
				end if
		                ' DEM --> Start of Code added for Full Moderation
				if (AdminAllowed = 1 and Reply_Status > 1) then
					ReplyString = "REPLY_ID=" & Reply_ReplyID & "&CAT_ID=" & Cat_ID & "&FORUM_ID=" & Forum_ID & "&TOPIC_ID=" & Topic_ID
					Response.Write "                       <a href=""JavaScript:openWindow('pop_moderate.asp?" & ReplyString & "')"">" & getCurrentIcon(strIconFolderModerate,"Approuver /En Attente /Rejeter cette Réponse","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewline
				end if
				' DEM --> End of Code added for Full Moderation
			end if
			Response.Write	"                      <hr noshade size=""" & strFooterFontSize & """></td>" & vbNewLine & _
					"                    </tr>" & vbNewLine & _
					"                    <tr>" & vbNewLine & _
					"                      <td valign=""top"" height=""100%""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """><span class=""spnMessageText"" id=""msg"">"
			if Request.QueryString("SearchTerms") <> "" then
				Response.Write	SearchHiLite(formatStr(Reply_Content))
			else
				Response.Write	formatStr(Reply_Content)
			end if
			Response.Write	"</span id=""msg""></font></td>" & vbNewLine & _
					"                    </tr>" & vbNewLine
			if CanShowSignature = 1 and Reply_Sig = 1 and Reply_MemberSig <> "" then
				Response.Write	"                    <tr>" & vbNewLine & _
						"                      <td valign=""bottom""><hr noshade size=""" & strFooterFontSize & """><font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><span class=""spnMessageText"">" & formatStr(Reply_MemberSig) & "</span></font></td>" & vbNewLine & _
						"                    </tr>" & vbNewLine
			end if
			if strEditedByDate = "1" and Reply_LastEditBy <> "" then
				if Reply_LastEditBy <> Reply_Author then 
					Reply_LastEditByName = getMemberName(Reply_LastEditBy)
				else
					Reply_LastEditByName = chkString(Reply_MemberName,"display")
				end if
				Response.Write	"                    <tr>" & vbNewLine & _
						"                      <td valign=""bottom""><hr noshade size=""" & strFooterFontSize & """ color=""" & CColor & """><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """ color=""" & strForumFontColor & """>" & _
						"Dernière modification par - " & Reply_LastEditByName & " le " & chkDate(Reply_LastEdit, " " ,true) & "</font></td>" & vbNewLine & _
						"                    </tr>" & vbNewLine
			end if
			Response.Write	"                    <tr>" & vbNewLine & _
					"                      <td valign=""bottom"" align=""right"" height=""20""><a href=""#top"">" & getCurrentIcon(strIconGoUp,"Haut De Page","align=""right""") & "</a></td>" & vbNewLine & _
					"                    </tr>" & vbNewLine & _
					"                  </table>" & vbNewLine & _
					"                </td>" & vbNewLine & _
					"              </tr>" & vbNewLine
			intI  = intI + 1
			if intI = 2 then 
				intI = 0
			end if
		next
	end if
	Response.Write	"              <tr>" & vbNewLine
	if maxpages > 1 then
		Call DropDownPaging(2)
	else
		Response.Write	"                <td align=""center"" bgcolor=""" & strHeadCellColor & """ width=""" & strTopicWidthLeft & """"
		if lcase(strTopicNoWrapLeft) = "1" then Response.Write(" nowrap")
		Response.Write	"><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """> </font></b></td>" & vbNewLine
	end if
	Response.Write	"                <td align=""center"" bgcolor=""" & strHeadCellColor & """ width=""" & strTopicWidthRight & """"
	if lcase(strTopicNoWrapRight) = "1" then Response.Write(" nowrap")
	'if maxpages > 1 and (AdminAllowed = 1) then Response.Write(" colspan=""2""")
	Response.Write	"><b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>" & vbNewLine
	if strShowTopicNav = "1" then
		Call Topic_nav()
	else
		Response.Write("Topic")
	end if
	Response.Write	"</font></b></td>" & vbNewLine
	if (AdminAllowed = 1) then
		if maxpages > 1 then
	        	Response.Write	"                <td align=""right"" bgcolor=""" & strHeadCellColor & """ nowrap><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """> </font></td>" & vbNewLine
		end if
		Response.Write	"                <td align=""right"" bgcolor=""" & strHeadCellColor & """ nowrap>" & vbNewLine
		call AdminOptions()
		Response.Write	"</td>" & vbNewLine
	else
        	Response.Write	"                <td align=""right"" bgcolor=""" & strHeadCellColor & """ nowrap><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """> </font></td>" & vbNewLine
	end if
	Response.Write	"              </tr>" & vbNewLine & _
			"            </table>" & vbNewLine & _
			"          </td>" & vbNewLine & _
			"        </tr>" & vbNewLine & _
			"      </table>" & vbNewLine & _
			"    </td>" & vbNewLine & _
			"  </tr>" & vbNewLine & _
			"</table>" & vbNewLine
	if maxpages > 1 then
		Response.Write	"<table align=""center"" border=""0"" cellPadding=""0"" cellSpacing=""1"" width=""95%"">" & vbNewLine & _
				"  <tr>" & vbNewLine & _
				"    <td align=""left"" valign=""top""><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>"
		if mypage > 1 then Response.Write("<a href=""topic.asp?" & ArchiveLink & "TOPIC_ID=" & Topic_ID & "&whichpage=" & mypage-1 & SearchLink & """ title=""Allez à la page précédente dans ce sujet""" & dWStatus("Allez à la page précédente dans ce sujet") & ">Page Précédente</a>")
		'if mypage > 1 then Response.Write("<a href=""javascript: onclick=document.PageNum1.whichpage.value=" & mypage-1 & ";document.PageNum1.submit();"" title=""Allez à la page précédente dans ce sujet""" & dWStatus("Allez à la page précédente dans ce sujet") & ">Page Précédente</a>")
		if mypage > 1 and mypage < maxpages then Response.Write(" | ")
		if mypage < maxpages then Response.Write("<a href=""topic.asp?" & ArchiveLink & "TOPIC_ID=" & Topic_ID & "&whichpage=" & mypage+1 & SearchLink & """ title=""Allez à la page suivante de ce sujet""" & dWStatus("Allez à la page suivante de ce sujet") & ">Page Suivante</a>")
		'if mypage < maxpages then Response.Write("<a href=""javascript: onclick=document.PageNum1.whichpage.value=" & mypage+1 & ";document.PageNum1.submit();"" title=""Allez à la page suivante de ce sujet""" & dWStatus("Allez à la page suivante de ce sujet") & ">Page Suivante</a>")
		Response.Write	"</td>" & vbNewLine & _
			"  </tr>" & vbNewLine & _
			"</table>" & vbNewLine
	end if
	Response.Write	"<table align=""center"" border=""0"" cellPadding=""0"" cellSpacing=""0"" width=""95%"">" & vbNewLine & _
			"  <tr>" & vbNewLine & _
			"    <td>" & vbNewLine & _
			"      <table width=""100%"">" & vbNewLine & _
			"        <tr>" & vbNewLine & _
			"          <td align=""center"" valign=""top"" width=""50%"">" & vbNewLine
	Call PostingOptions()
	Response.Write	"</td>" & vbNewLine & _
			"          <td align=""right"" valign=""top"" width=""50%"" nowrap>" & vbNewLine
%>
	<!--#INCLUDE FILE="inc_jump_to.asp" -->
<%
	Response.Write	"          </td>" & vbNewLine & _
			"        </tr>" & vbNewLine & _
			"      </table>" & vbNewLine

	if strShowQuickReply = "1" and strDBNTUserName <> "" and ((Cat_Status = 1) and (Forum_Status = 1) and (Topic_Status = 1)) and ArchiveView = "" then
		call QuickReply()
	end if

        WriteFooter
end if

sub GetFirst()
	CColor = strForumFirstCellColor
	Response.Write	"              <tr>" & vbNewLine & _
			"                <td bgcolor=""" & strForumFirstCellColor & """ valign=""top"" width=""" & strTopicWidthLeft & """"
	if lcase(strTopicNoWrapLeft) = "1" then Response.Write(" nowrap")
	Response.Write	">" & vbNewLine & _
			"                <p><font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><b><span class=""spnMessageText"">" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b></font><br />" & vbNewLine
	if strShowRank = 1 or strShowRank = 3 then
 		Response.Write	"                <font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """><small>" & ChkString(getMember_Level(Member_Title, Member_Level, Member_Posts),"display") & "</small></font><br />" & vbNewLine
	end if
	if strShowRank = 2 or strShowRank = 3 then
		Response.Write	"                " & getStar_Level(Member_Level, Member_Posts) & "<br />" & vbNewLine
	end if
 	Response.Write	"                </p>" & vbNewLine & _
			"                <p>" & vbNewLine
	if (Member_Photo > " ") then
		Response.Write "<table width=""" & intAvatarWidth & """ height= """ & intAvatarHeight & """ cellspacing=""0"" cellpadding=""0"" border=""0"" style="" background-image: url('" & Member_Photo & "');background-repeat: no-repeat; background-position: center;"">" & vbNewLine & _
					"	<tr>" & vbNewLine & _
					"			<td align=""center""><img src=""" & strImageURL & "noavatar.gif"" width=""96"" height=""96"" border=""0""></td>" & vbNewLine & _
					"		</tr>" & vbNewLine & _
					"	</table>" & vbNewLine
	end if
'	##### Avatar Mod #####
	if (Member_Avatar > " ") and (Member_Avatar <> "1") and (Member_Avatar <> "noavatar.gif") then
		Response.Write "<table width=""" & intAvatarWidth & """ height= """ & intAvatarHeight & """ cellspacing=""0"" cellpadding=""0"" border=""0"" style="" background-image: url('" & Member_Avatar & "');background-repeat: no-repeat; background-position: center;"">" & vbNewLine & _
					"	<tr>" & vbNewLine & _
					"			<td align=""center""><img src=""" & strImageURL & "noavatar.gif"" width=""96"" height=""96"" border=""0""></td>" & vbNewLine & _
					"		</tr>" & vbNewLine & _
					"	</table>" & vbNewLine
	end if
'	### Avatar Mod End ###
	if strCountry = "1" and trim(Member_Country) <> "" then
		Response.Write	"                <font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """><small>" & Member_Country & "</small></font><br /><img src=""" & strImageURL & Member_Country & ".gif""><br />" & vbNewLine
	end if
	Response.Write	"                <font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """><small>" & Member_Posts & " Messages</small></font></p></td>" & vbNewLine & _
			"                <td bgcolor=""" & strForumFirstCellColor & """ width=""" & strTopicWidthRight & """"
	if lcase(strTopicNoWrapRight) = "1" then Response.Write(" nowrap")
	if (AdminAllowed = 1) and (maxpages > 1) then
		Response.Write	(" colspan=""3"" ")
	else
		Response.Write	(" colspan=""2"" ")
	end if
	Response.Write	"valign=""top"">" & vbNewLine & _
			"                  <table width=""100%"" height=""100%"" border=""0"" cellspacing=""0"" cellpadding=""0"">" & vbNewLine & _
			"                    <tr>" & vbNewLine & _
			"                      <td valign=""top"">" & vbNewLine
	if Topic_Status < 2 then
		Response.Write  "                      " & getCurrentIcon(strIconPosticon,"","hspace=""3""") & "<font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>Mis le - " & ChkDate(Topic_Date, " : " ,true) & "</font>" & vbNewline
	elseif Topic_Status = 2 then
		Response.Write  "                      <font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize  & """>NON MODERE!!!</font>" & vbNewline
	elseif Topic_Status = 3 then
		Response.Write  "                      " & getCurrentIcon(strIconPosticonHold,"","hspace=""3""") & "<font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>ON HOLD</font>" & vbNewline
	end if
	Response.Write	"                       " & profileLink(getCurrentIcon(strIconProfile,"Aperçu Profil","align=""absmiddle"" hspace=""6"""),TMember_ID) & vbNewLine
	if mLev > 2 or Member_ReceiveMail = "1" then 
		if (mlev <> 0) or (mlev = 0 and  strLogonForMail <> "1") then 
			Response.Write	"                       <a href=""JavaScript:openWindow('pop_mail.asp?id=" & TMember_ID & "')"">" & getCurrentIcon(strIconEmail," Envoyer Email","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
		end if
	end if
	if (strHomepage = "1") then
		if Member_Homepage <> " " then
			Response.Write	"                       <a href=""" & Member_Homepage & """ target=""_blank"">" & getCurrentIcon(strIconHomepage,"Allez à " & ChkString(Member_Name,"display") & "  Sur Son Site Web","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
		end if
	end if
	if (AdminAllowed = 1 or TMember_ID = MemberID) then
		if ((Cat_Status <> 0) and (Forum_Status <> 0) and (Topic_Status <> 0)) or (AdminAllowed = 1) then
			Response.Write	"                       <a href=""post.asp?" & ArchiveLink & "method=EditTopic&REPLY_ID=" & Topic_ID & "&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconEditTopic,"Editer Sujet","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
		end if
	end if
	if (strAIM = "1") then
		if Trim(Member_AIM) <> "" then
			Response.Write	"                       <a href=""JavaScript:openWindow('pop_messengers.asp?mode=AIM&ID=" & TMember_ID & "')"">" & getCurrentIcon(strIconAIM,"Envoyer " & ChkString(Member_Name,"display") & " à AOL message","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
		end if
	end if
	if (strICQ = "1") then
		if Trim(Member_ICQ) <> "" then
			Response.Write	"                       <a href=""JavaScript:openWindow6('pop_messengers.asp?mode=ICQ&ID=" & TMember_ID & "')"">" & getCurrentIcon(strIconICQ,"Envoyer " & ChkString(Member_Name,"display") & " à ICQ Message","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
		end if
	end if
	if (strMSN = "1") then
		if Trim(Member_MSN) <> "" then
			Response.Write	"                       <a href=""JavaScript:openWindow('pop_messengers.asp?mode=MSN&ID=" & TMember_ID & "')"">" & getCurrentIcon(strIconMSNM,"Cliquez pour voir " & ChkString(Member_Name,"display") & "  MSN Messenger address","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
		end if
	end if
	if (strSKYPE = "1") then
		if Trim(Member_SKYPE) <> "" then
			Response.Write	"                       <a href=""JavaScript:openWindow('pop_messengers.asp?mode=SKYPE&ID=" & TMember_ID & "')"">" & getCurrentIcon(strIconSKYPE,"Regardez l'adresse du téléphone Skype " & ChkString(Member_Name,"display") & "","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
		end if
	end if
	if (strYAHOO = "1") then
		if Trim(Member_YAHOO) <> "" then
			Response.Write	"                       <a href=""http://edit.yahoo.com/config/send_webmesg?.target=" & ChkString(Member_YAHOO, "urlpath") & "&.src=pg"" target=""_blank"">" & getCurrentIcon(strIconYahoo,"Envoyer " & ChkString(Member_Name,"display") & " à Yahoo! Message","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
		end if
	end if
	If (Member_PM = "1" and strPMStatus = "1") Then
		if Trim(Member_PM) <> "" then
			Response.Write	"                <a href=""privatesend.asp?method=Topic&mname=" & ChkString(Member_Name,"display") & """>" & getCurrentIcon(strIconPmprivatemessage,"Envoyer à " & ChkString(Member_Name,"display") & " un Message Privé","align=""absmiddle"" hspace=""0""") & "</a>" & vbNewLine
		End If
	End IF
	if ((Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status = 1) or (AdminAllowed = 1 and Topic_Status <= 1) and ArchiveView = "" ) then
		Response.Write	"                       <a href=""post.asp?method=TopicQuote&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconReplyTopic,"Répondre Avec Citation","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
	end if
	if (strIPLogging = "1") then
		if (AdminAllowed = 1) then
			Response.Write	"                       <a href=""JavaScript:openWindow('pop_viewip.asp?" & ArchiveLink & "mode=getIP&TOPIC_ID=" & TopicID & "&FORUM_ID=" & Forum_ID & "')"">" & getCurrentIcon(strIconIP,"Voir Adresse IP d'Utilisateur","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
		end if
	end if
	if (AdminAllowed = 1) or (TMember_ID = MemberID and Topic_Replies < 1) then
		Response.Write	"                       <a href=""JavaScript:openWindow('pop_delete.asp?" & ArchiveLink & "mode=Topic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconDeleteReply,"Supprimer Sujet","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewLine
	end if
	' DEM --> Start of Code added for Full Moderation
	if (AdminAllowed = 1 and Topic_Status > 1) then
		TopicString = "TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID
		Response.Write  "                       <a href=""JavaScript:openWindow('pop_moderate.asp?" & TopicString & "')"">" & getCurrentIcon(strIconFolderModerate,"Approuver/En Attente/Rejecter ce Sujet","align=""absmiddle"" hspace=""6""") & "</a>" & vbNewline
	End if
	' End of Code added for Full Moderation
	Response.Write	"                      <hr noshade size=""" & strFooterFontSize & """></td>" & vbNewLine & _
			"                    </tr>" & vbNewLine & _
			"                    <tr>" & vbNewLine & _
			"                      <td valign=""top"" height=""100%""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """><span class=""spnMessageText"" id=""msg"">"
	if Request.QueryString("SearchTerms") <> "" then
		Response.Write	SearchHiLite(formatStr(Topic_Message))
	else
		Response.Write	formatStr(Topic_Message)
	end if
	Response.Write	"</span id=""msg""></font></td>" & vbNewLine & _
			"                    </tr>" & vbNewLine
	if CanShowSignature = 1 and Topic_Sig = 1 and Topic_MemberSig <> "" then
		Response.Write	"                    <tr>" & vbNewLine & _
				"                      <td valign=""bottom""><hr noshade size=""" & strFooterFontSize & """><font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><span class=""spnMessageText"">" & formatStr(Topic_MemberSig) & "</span></font></td>" & vbNewLine & _
				"                    </tr>" & vbNewLine
	end if
	if strEditedByDate = "1" and Topic_LastEditBy <> "" then
		if Topic_LastEditBy <> Topic_Author then 
			Topic_LastEditByName = getMemberName(Topic_LastEditBy)
		else
			Topic_LastEditByName = chkString(Member_Name,"display")
		end if
		Response.Write	"                    <tr>" & vbNewLine & _
				"                      <td valign=""bottom""><hr noshade size=""" & strFooterFontSize & """ color=""" & strForumFirstCellColor & """><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """ color=""" & strForumFontColor & """>" &_
				"Dernière modification par - " & Topic_LastEditByName & " le " & chkDate(Topic_LastEdit, " ", true) & "</font></td>" & vbNewLine & _
				"                    </tr>" & vbNewLine
	end if
	Response.Write	"                  </table>" & vbNewLine & _
			"                </td>" & vbNewLine & _
			"              </tr>" & vbNewLine
End Sub


sub PostingOptions() 
	Response.Write	"          <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine
	if (mlev = 4 or mlev = 3 or mlev = 2 or mlev = 1) or (lcase(strNoCookies) = "1") or (strDBNTUserName = "") then
		if ((Cat_Status = 1) and (Forum_Status = 1)) then
			Response.Write	"          <a href=""post.asp?method=Topic&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconFolderNewTopic,"","align=""absmiddle""") & "</a> <a href=""post.asp?method=Topic&FORUM_ID=" & Forum_ID & """>Nouveau Sujet</a>" & vbNewLine
		else
			if (AdminAllowed = 1) then
				Response.Write	"          <a href=""post.asp?method=Topic&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconFolderLocked,"","align=""absmiddle""") & "</a> <a href=""post.asp?method=Topic&FORUM_ID=" & Forum_ID & """>Page Suivante</a>" & vbNewLine
			else
				Response.Write	"          " & getCurrentIcon(strIconFolderLocked,"","align=""absmiddle""") & " Forum Fermé" & vbNewLine
			end if 
		end if 
		if ((Cat_Status = 1) and (Forum_Status = 1) and (Topic_Status = 1)) and ArchiveView = "" then
			Response.Write	"          <a href=""post.asp?method=Reply&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconReplyTopic,"","align=""absmiddle""") & "</a> <a href=""post.asp?method=Reply&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>Répondre au Sujet</a>" & vbNewLine
		else 
			if ((AdminAllowed = 1 and Topic_Status <= 1) and ArchiveView = "")  then
				Response.Write	"          <a href=""post.asp?method=Reply&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>"
				' DEM --> Added if statement to show normal icon for unmoderated posts.
				if Topic_Status = 1 and Cat_Status <> 0 and Forum_Status <> 0 then
					Response.Write	getCurrentIcon(strIconReplyTopic,"","align=""absmiddle""") & "</a> "
				else
					Response.Write	getCurrentIcon(strIconClosedTopic,"","align=""absmiddle""") & "</a> "
				end if 
				Response.Write	"<a href=""post.asp?" & ArchiveLink & "method=Reply&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>Répondre au Sujet</a>" & vbNewLine
			else 
				if Topic_Status = 0 then
					Response.Write	getCurrentIcon(strIconClosedTopic,"","align=""absmiddle""") & " Sujet Verrouillé" & vbNewline
				end if
			end if
		end if 
		if lcase(strEmail) = "1" and Topic_Status < 2 then 
			if Cat_Status <> 0 and Forum_Status <> 0 and Topic_Status <> 0 and mLev > 0 then
				if strSubscription > 0 and Cat_Subscription > 0 and Forum_Subscription > 0 then
					if InArray(strTopicSubs, Topic_ID) then
						Response.Write "          <br />" & ShowSubLink ("U", Cat_ID, Forum_ID, Topic_ID, "Y") & vbNewLine
					elseif strBoardSubs <> "Y" and not(InArray(strForumSubs,Forum_ID) or InArray(strCatSubs,Cat_ID)) then
						Response.Write "          <br />" & ShowSubLink ("S", Cat_ID, Forum_ID, Topic_ID, "Y") & vbNewLine
					end if
				end if
			end if
			if ((mlev <> 0) or (mlev = 0 and strLogonForMail <> "1")) and lcase(strShowSendToFriend) = "1" then
				Response.Write	"          <br /><a href=""JavaScript:openWindow('pop_send_to_friend.asp?url=" & strForumURL & "topic.asp?TOPIC_ID=" & Topic_ID & "')"">" & getCurrentIcon(strIconSendTopic,"","align=""absmiddle""") & "</a> <a href=""JavaScript:openWindow('pop_send_to_friend.asp?url=" & strForumURL & "topic.asp?TOPIC_ID=" & Topic_ID & "')"">Envoyer ce Sujet à un Ami</a>" & vbNewLine
			end if 
		end if 
		if lcase(strShowPrinterFriendly) = "1" and Topic_Status < 2 then
			Response.Write	"          <br /><a href=""JavaScript:openWindow5('pop_printer_friendly.asp?" & ArchiveLink & "TOPIC_ID=" & Topic_ID & "')"">" & getCurrentIcon(strIconPrint,"","align=""absmiddle""") & "</a> <a href=""JavaScript:openWindow5('pop_printer_friendly.asp?" & ArchiveLink & "TOPIC_ID=" & Topic_ID & "')"">Imprimer le Sujet</a>" & vbNewLine
		end if
	end if
 
	Response.Write	"          </font>"
end sub 

sub AdminOptions() 
	Response.Write	"                <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine
	if (AdminAllowed = 1) 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,"Déverrouiller Catégorie","") & "</a>" & vbNewLine
			else
				Response.Write	"                " & getCurrentIcon(strIconFolderUnlocked,"Catégorie Verrouillée","") & vbNewLine
			end if
		else 
			if (Forum_Status = 0) then
				Response.Write	"                <a href=""JavaScript:openWindow('pop_open.asp?mode=Forum&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconFolderUnlocked,"Verrouiller Forum","") & "</a>" & vbNewLine
			else
				if (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(strIconFolderLocked,"Verrouiller Sujet","") & "</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(strIconFolderUnlocked,"Déverrouiller Sujet","") & "</a>" & vbNewLine
				end if
			end if
		end if
		if ((Cat_Status <> 0) and (Forum_Status <> 0) and (Topic_Status <> 0)) or (AdminAllowed = 1) then
			Response.Write	"                <a href=""post.asp?" & ArchiveLink & "method=EditTopic&REPLY_ID=" & Topic_ID & "&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconFolderPencil,"Editer Sujet","hspace=""0""") & "</a>" & vbNewLine
		end if
		Response.Write	"                <a href=""JavaScript:openWindow('pop_delete.asp?" & ArchiveLink & "mode=Topic&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "')"">" & getCurrentIcon(strIconFolderDelete,"Supprimer Sujet","") & "</a>" & vbNewLine & _
				"                <a href=""post.asp?method=Topic&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconFolderNewTopic,"Nouveau Sujet","") & "</a>" & vbNewLine
		if Topic_Status <= 1 and ArchiveView = "" then
			Response.Write	"                <a href=""post.asp?method=Reply&TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & """>" & getCurrentIcon(strIconReplyTopic,"Répondre au Sujet","") & "</a>" & vbNewLine
		end if
	end if 
	' DEM --> Start of Code added for Full Moderation
	if (AdminAllowed = 1 and CheckForUnModeratedPosts("TOPIC", Cat_ID, Forum_ID, Topic_ID) > 0) then
		TopicString = "TOPIC_ID=" & Topic_ID & "&FORUM_ID=" & Forum_ID & "&CAT_ID=" & Cat_ID & "&REPLY_ID=X"
		Response.Write "                <a href=""JavaScript:openWindow('pop_moderate.asp?" & TopicString & "')"">" & getCurrentIcon(strIconFolderModerate,"Approuver/En Attente/Rejecter tous les messages de ce Sujet","") & "</a>" & vbNewline
	end if
	' DEM --> End of Code added for Full Moderation
	Response.Write "                </font>"
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("                <form name=""PageNum" & fnum & """ action=""topic.asp"">" & vbNewLine)
		Response.Write("                <td bgcolor=""" & strHeadCellColor & """ nowrap><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """>" & vbNewLine)
		if Archiveview = "true" then Response.Write("                <input type=""hidden"" name=""ARCHIVE"" value=""" & ArchiveView & """>" & vbNewLine)
		Response.Write("                <input type=""hidden"" name=""TOPIC_ID"" value=""" & Request("TOPIC_ID") & """>" & vbNewLine)
		Response.Write("                <b>Page: </b><select name=""whichpage"" size=""1"" onchange=""ChangePage(" & fnum & ");"">" & vbNewLine)
		for counter = 1 to maxpages
			if counter <> cLng(pge) then   
				Response.Write "                	<option value=""" & counter &  """>" & counter & "</option>" & vbNewLine
			else
				Response.Write "                	<option selected value=""" & counter &  """>" & counter & "</option>" & vbNewLine
			end if
		next
		Response.Write("                </select><b> sur " & maxpages & "</b>" & vbNewLine)
		if Request.QueryString("SearchTerms") <> "" then Response.Write("                <input type=""hidden"" name=""SearchTerms"" value=""" & Server.HTMLEncode(Request.QueryString("SearchTerms")) & """>" & vbNewLine)
		Response.Write("                </font></td>" & vbNewLine)
		Response.Write("                </form>" & vbNewLine)
	end if
	top = "0"
end sub 

Sub Topic_nav()    

	if prevTopic = "" then
		strSQL = "SELECT T_SUBJECT, TOPIC_ID "
		strSql = strSql & "FROM " & strActivePrefix & "TOPICS "
		strSql = strSql & "WHERE T_LAST_POST > '" & Topic_LastPost
		strSql = strSql & "' AND FORUM_ID = " & Forum_ID
		strSql = strSql & " AND T_STATUS < 2"  ' Ignore unapproved/held posts
		strSql = strSql & " ORDER BY T_LAST_POST;"

		set rsPrevTopic = my_conn.Execute(TopSQL(strSql,1))

		if rsPrevTopic.EOF then
			prevTopic = getCurrentIcon(strIconBlank,"","align=""top"" hspace=""6""")
		else
			prevTopic = "<a href=""topic.asp?" & ArchiveLink & "TOPIC_ID=" & rsPrevTopic("TOPIC_ID") & """>" & getCurrentIcon(strIconGoLeft,"Page Précédente","align=""top"" hspace=""6""") & "</a>"
		end if

		rsPrevTopic.close
		set rsPrevTopic = nothing
	else
		prevTopic = prevTopic
	end if

	if NextTopic = "" then
		strSQL = "SELECT T_SUBJECT, TOPIC_ID "
		strSql = strSql & "FROM " & strActivePrefix & "TOPICS "
		strSql = strSql & "WHERE T_LAST_POST < '" & Topic_LastPost
		strSql = strSql & "' AND FORUM_ID = " & Forum_ID
		strSql = strSql & " AND T_STATUS < 2"  ' Ignore unapproved/held posts
		strSql = strSql & " ORDER BY T_LAST_POST DESC;"

		set rsNextTopic = my_conn.Execute(TopSQL(strSql,1))

		if rsNextTopic.EOF then
			nextTopic = getCurrentIcon(strIconBlank,"","align=""top"" hspace=""6""")
		else
			nextTopic = "<a href=""topic.asp?" & ArchiveLink & "TOPIC_ID=" & rsNextTopic("TOPIC_ID") & """>" & getCurrentIcon(strIconGoRight,"Page Suivante","align=""top"" hspace=""6""") & "</a>"
		end if

		rsNextTopic.close
		set rsNextTopic = nothing
	else
		nextTopic = nextTopic
	end if

	Response.Write ("                " & prevTopic & "<b><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """> Sujet </font></b>" & nextTopic)

end sub

function SearchHiLite(fStrMessage)
	'function derived from HiLiTeR by 2eNetWorX
	fArr = split(replace(Request.QueryString("SearchTerms"),";",""), ",")
	strBuffer = ""
	for iPos = 1 to len(fStrMessage)
		bChange = False
		'Looks for html tags
		if mid(fStrMessage, iPos, 1) = "<" then
			bInHTML = True
		end if
		'Looks for End of html tags
		if bInHTML = True then
			if mid(fStrMessage, iPos, 1) = ">" then
				bInHTML = False
			end if
		end if
		if bInHTML <> True then  
			for i = 0 to UBound(fArr)
				if fArr(i) <> "" then
					if lcase(mid(fStrMessage, iPos, len(fArr(i)))) = lcase(fArr(i)) then
						bChange = True
						strBuffer = strBuffer & "<span class=""spnSearchHighlight"" id=""hilite"">" & _ 
						mid(fStrMessage, iPos, len(fArr(i))) & "</span id=""hilite"">"
						iPos = iPos + len(fArr(i)) - 1
					end if
				end if
			next
		end if
		if Not bChange then
			strBuffer = strBuffer & mid(fStrMessage, iPos, 1)
		end if
	next
	SearchHiLite = strBuffer
end function

Sub QuickReply()
	intSigDefault = getSigDefault(MemberID)
	Response.Write	"    <script language=""JavaScript"" type=""text/javascript"" src=""inc_code.js""></script>" & vbNewLine & _
			"      <table width=""100%"" border=""0"" cellspacing=""0"" cellpadding=""0"" align=""center"">" & vbNewLine & _
			"        <tr>" & vbNewLine & _
			"          <td bgcolor=""" & strPopUpBorderColor & """>" & vbNewLine & _
			"            <table width=""100%"" border=""0"" cellspacing=""1"" cellpadding=""1"">" & vbNewLine & _
			"              <form name=""PostTopic"" method=""post"" action=""post_info.asp"" onSubmit=""return validate();"">" & vbNewLine & _
			"              <input name=""ARCHIVE"" type=""hidden"" value=""" & ArchiveView & """>" & vbNewLine & _
			"              <input name=""Method_Type"" type=""hidden"" value=""Reply"">" & vbNewLine & _
			"              <input name=""TOPIC_ID"" type=""hidden"" value=""" & Topic_ID & """>" & vbNewLine & _
			"              <input name=""FORUM_ID"" type=""hidden"" value=""" & Forum_ID & """> " & vbNewLine & _
			"              <input name=""CAT_ID"" type=""hidden"" value=""" & Cat_ID & """>" & vbNewLine & _
			"              <input name=""Refer"" type=""hidden"" value=""" & request.servervariables("SCRIPT_NAME") & "?" & chkString(Request.QueryString,"refer") & """>" & vbNewLine & _
			"              <input name=""UserName"" type=""hidden"" value=""" & strDBNTUserName & """>" & vbNewLine & _
			"              <input name=""Password"" type=""hidden"" value=""" & Request.Cookies(strUniqueID & "User")("Pword") & """>" & vbNewLine & _
			"              <tr>" & vbNewLine & _
			"                <td bgColor=""" & strHeadCellColor & """ noWrap vAlign=""top"" colspan=""2""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """><b>Réponse Rapide</b></font></td>" & vbNewLine & _
			"              </tr>" & vbNewLine & _
			"              <tr>" & vbNewLine & _
			"                <td bgColor=""" & strForumCellColor & """ noWrap vAlign=""top"" align=""right""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """><span class=""spnMessageText""><b>Message: </b><br />" & vbNewLine & _
			"                <br />" & vbNewLine & _
			"                  <table border=""0"">" & vbNewLine & _
			"                    <tr>" & vbNewLine & _
			"                      <td align=""left"" nowrap><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """ color=""" & strForumFontColor & """>" & vbNewLine
	if strAllowHTML = "1" then
		Response.Write	"                      * HTML OUVERT<br />" & vbNewLine
	else
		Response.Write	"                      * HTML FERMER<br />" & vbNewLine
	end if
	if strAllowForumCode = "1" then
		Response.Write	"                      * <a href=""JavaScript:openWindow6('pop_forum_code.asp')"">Forum Code</a> OUVERT<br />" & vbNewLine
	else
		Response.Write	"                      * Forum Code FERMER<br />" & vbNewLine
	end if
	if strSignatures = "1" then
		Response.Write	"                      <br /><input name=""Sig"" id=""Sig"" type=""checkbox"" value=""yes""" & chkCheckbox(intSigDefault,1,true) & "><label for=""Sig"">Inclure Signature</label><br />" & vbNewLine
	end if
	Response.Write	"                      </font></td>" & vbNewLine & _
			"                    </tr>" & vbNewLine & _
			"                  </table>" & vbNewLine & _
			"                </span></font></td>" & vbNewLine & _
			"                <td width=""" & strTopicWidthRight & """ bgColor=""" & strForumCellColor & """><textarea name=""Message"" cols=""50"" rows=""6"" wrap=""VIRTUAL"" style=""width:100%""></textarea><br /></td>" & vbNewLine & _
			"              </tr>" & vbNewLine & _
			"              <tr>" & vbNewLine & _
			"                <td bgColor=""" & strForumCellColor & """ noWrap align=""center"" colspan=""2""><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strHeadFontColor & """><input name=""Submit"" type=""submit"" value=""Envoyer Réponse""> <input name=""Preview"" type=""button"" value=""Apercu Réponse"" onclick=""OpenPreview()"">"
	'Response.Write	" <input name=""Reset"" type=""reset"" value=""Réinitialiser Le Formulaire""></font></td>" & vbNewLine & _
	Response.Write	"</font></td>" & vbNewLine & _
			"              </tr>" & vbNewLine & _
			"              </form>" & vbNewLine & _
			"            </table>" & vbNewLine & _
			"          </td>" & vbNewLine & _
			"        </tr>" & vbNewLine & _
			"      </table>" & vbNewLine & _
			"      <br />" & vbNewLine
end sub
%>

Cordially,
Maxime

Taxation consists in so plucking the goose to get the most out of feathers with the least possible cries.(Jean-Baptiste Colbert)

Go to Top of Page

Carefree
Advanced Member

Philippines
4207 Posts

Posted - 15 October 2014 :  04:42:18  Show Profile
For the mp3 and pdf mods, you will have to change "inc_func_common.asp".


Look for the following line:

   ReplaceMP3Tags = strTempString

Above it, insert these:

	If Request("SearchTerms")>"" and inStr(fString,"[mp3]") > 0 Then
		intStarting=inStr(fString,"[mp3]")+5
		intEnding=inStr(fString,"[/mp3]")
		strTempString=mid(fString,intStarting,intEnding-intStarting)
		Response.Write "<script language=""javascript"">EmbedMP3(""" & strTempString & """,290,300,false);</script><br />"
	End If



Next, look for the following line: ReplacePDFTags = strTempString Above it, insert these: If Request("SearchTerms")>"" and inStr(fString,"[pdf]") > 0 Then intStarting=inStr(fString,"[pdf]")+5 intEnding=inStr(fString,"[/pdf]") strTempString=mid(fString,intStarting,intEnding-intStarting) Response.Write "<script language=""javascript"">EmbedPDF(""" & strTempString & """,625,475);</script><br />" End If

Edited by - Carefree on 15 October 2014 05:02:13
Go to Top of Page

Maxime
Average Member

France
521 Posts

Posted - 15 October 2014 :  05:14:53  Show Profile  Visit Maxime's Homepage
Hello Carefree,

Thank you for the code, there is the pdf file is not displayed, just the download link and the warning note. For MP3, the first file is displayed, but the other not, and by clicking on the MP3 does not work it said there was an error.

inc_func_common.asp
http://www.chatquiz.org/fichier/inc_func_common.txt

Cordially,
Maxime

Taxation consists in so plucking the goose to get the most out of feathers with the least possible cries.(Jean-Baptiste Colbert)

Go to Top of Page

Carefree
Advanced Member

Philippines
4207 Posts

Posted - 15 October 2014 :  05:51:59  Show Profile
I emailed it to you, there's something gone wrong with the [code][/code] and [scrollcode][/scrollcode] functions here.

Edited by - Carefree on 15 October 2014 06:29:31
Go to Top of Page

HuwR
Forum Admin

United Kingdom
20584 Posts

Posted - 15 October 2014 :  06:50:13  Show Profile  Visit HuwR's Homepage
quote:
Originally posted by Carefree

I emailed it to you, there's something gone wrong with the [code][/code] and [scrollcode][/scrollcode] functions here.


What seems to be the issue with the code tags ?

MVC .net dev/test site | MVC .net running on Raspberry Pi
Go to Top of Page

Carefree
Advanced Member

Philippines
4207 Posts

Posted - 16 October 2014 :  09:04:51  Show Profile
They weren't working. Converted the entire asp file to left-aligned .txt format. Scrollcode had no function at all.
Go to Top of Page

Maxime
Average Member

France
521 Posts

Posted - 16 October 2014 :  09:53:33  Show Profile  Visit Maxime's Homepage
hello,

Yes that's exactly what happened to the file inc_func_common . asp with scrollcode, he had no elevators. I think the code in the file generated this error.

Cordially,
Maxime

Taxation consists in so plucking the goose to get the most out of feathers with the least possible cries.(Jean-Baptiste Colbert)


Edited by - Maxime on 16 October 2014 09:54:20
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.58 seconds. Powered By: Snitz Forums 2000 Version 3.4.07