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: MOD Implementation
 Mod User Level Moderation
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

BroIgnatius
New Member

56 Posts

Posted - 13 April 2008 :  08:21:30  Show Profile
Hi:

I found a Mod User Level Moderation post, but the discussion there progresses through bugs and such and make it disjointed to try to impliment the code.

Is there one central place where the finished working code can be found?

AnonJr
Moderator

United States
5768 Posts

Posted - 14 April 2008 :  08:14:24  Show Profile  Visit AnonJr's Homepage
Not likely. That's a fairly old topic.

I've found that when you run across old stuff like that, as much of a pain as it is, your best bet is to implement the original code and then work through the fixes. Just read ahead a little... trust me on that one.
Go to Top of Page

MaD2ko0l
Senior Member

United Kingdom
1053 Posts

Posted - 14 April 2008 :  08:52:25  Show Profile  Visit MaD2ko0l's Homepage
the original code has all the updates on it already apart from the addition of what dayve has posted a bit futher down the post

© 1999-2010 MaD2ko0l
Go to Top of Page

Carefree
Advanced Member

Philippines
4207 Posts

Posted - 15 April 2008 :  18:19:53  Show Profile
Here. I redid the instructions to match 3.4.06 for you:

Mod: User Level Moderation
Author: Rakesh Jain (GauravBhabu)
Posted: November 29, 2002
Updated: April 15, 2008 (for version 3.4.06)
December 01, 2002 07:40:00
December 30, 2002

To use the intRankLevel0 for Moderation instead of intRankLevel1

Current Options for Forum Level Moderation:
No Moderation for this forum - Value = 0
All Posts Moderated - value = 1
Original Posts Only Moderated- value = 2
Replies Only Moderated - value = 3

This Mod adds another level for Moderation as below.
The value of 9 is being assigned for this Moderation level.

Moderate New User Posts Only - value = 9

Mod Feature:
With this modification, Administrators will be able to set the Forum moderation so that only posts made by new users need to be moderated.

Installation Notes:

Modification is required in following files:
admin_config_ranks.asp
inc_header.asp
inc_func_common.asp
inc_moderation.asp
post.asp
post_info.asp
pop_help.asp


Instructions:

Step: 1
File: admin_config_ranks.asp
Lines: 190-191

Find the following lines:

			"                <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><b>Number:</b> </font><input type=""text"" name=""intRankLevel0"" size=""5"" value=""0"" readonly>" & vbNewLine & _
			"                " & getCurrentIcon(strIconSmileQuestion,"(Member who has less than Member Level 1 but more than Starting Member Level posts)","") & "</td>" & vbNewLine & _


Change them to say:

			" <font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """><b>Number:</b> </font><input type=""text"" name=""intRankLevel0"" size=""5"" value=""" & chkExistElse(intRankLevel0,0) & """>" & vbNewLine & _
			"                " & getCurrentIcon(strIconSmileQuestion,"(Member who has less than Member Level 1 posts)","") & "</td>" & vbNewLine & _


Lines: 80-82
Find the following lines:

if Request.Form("strRankLevel5") = "" then 
	Err_Msg = Err_Msg & "<li>You Must Enter a Value for Member Level 5 Name</li>"
end if

After them, add the following lines:

numRanklLevel0 = clng(Request.Form("intRankLevel0"))
if (numRanklLevel0) > cLng(Request.Form("intRankLevel1")) then 
	Err_Msg = Err_Msg & "<li>Rank Level 0 can not be higher than 1</li>"
elseif (numRanklLevel0) > cLng(Request.Form("intRankLevel2")) then 
	Err_Msg = Err_Msg & "<li>Rank Level 0 can not be higher than 2</li>"
elseif (numRanklLevel0) > cLng(Request.Form("intRankLevel3")) then 
	Err_Msg = Err_Msg & "<li>Rank Level 0 can not be higher than 3</li>"
elseif (numRanklLevel0) > cLng(Request.Form("intRankLevel4")) then 
	Err_Msg = Err_Msg & "<li>Rank Level 0 can not be higher than 4</li>"
elseif (numRanklLevel0) > cLng(Request.Form("intRankLevel5")) then 
	Err_Msg = Err_Msg & "<li>Rank Level 0 can not be higher than 5</li>"
end if


Step: 2
File: inc_header.asp
Lines: 35-37
Find the following lines:

%>
<!--#INCLUDE FILE="inc_func_common.asp" -->
<%

After them, add the following lines:

dim numMPostCount
numMPostCount = 0



Step: 3
File: inc_func_common.asp
Lines: 882-891
Find the following lines:

	if rsCheck.BOF or rsCheck.EOF or not(ChkQuoteOk(fName)) or not(ChkQuoteOk(fPassword)) then
		MemberID = -1
		chkUser = 0 '##  Invalid Password
		if strDBNTUserName <> "" and chkCookie = 1 then
			Call ClearCookies()
			strDBNTUserName = ""
		end if		
	else
		MemberID = rsCheck("MEMBER_ID")
		strDBNTUserName = rsCheck("M_NAME")

Change them to say:

	if rsCheck.BOF or rsCheck.EOF or not(ChkQuoteOk(fName)) or not(ChkQuoteOk(fPassword)) then
		MemberID = -1
		chkUser = 0 '##  Invalid Password
		if strDBNTUserName <> "" and chkCookie = 1 then
			Call ClearCookies()
			strDBNTUserName = ""
		end if		
	else
		numMPostCount = rsCheck("M_POSTS")
		MemberID = rsCheck("MEMBER_ID")
		strDBNTUserName = rsCheck("M_NAME")


Note: This particular line (in red above) results in a record-set error (item not found in DBase) on my site. When you go to configure ranks in Admin,
if you get a message of "Item cannot be found in the collection corresponding to the requested name or ordinal.", delete that line and it'll go away.

Step: 4
File: inc_moderation.asp
Lines: 66
Find the following line:

strSql = strSql & " AND T.FORUM_ID = F.FORUM_ID AND F.F_MODERATION in (1,2)" & " AND T.T_STATUS > 1 "

Change it to say:

strSql = strSql & " AND T.FORUM_ID = F.FORUM_ID AND F.F_MODERATION in (1,2,9)" & " AND T.T_STATUS > 1 "

Lines: 93
Find the following line:

strSql = strSql & " AND R.FORUM_ID = F.FORUM_ID AND F.F_MODERATION in (1,3)" & " AND R.R_STATUS > 1 "

Change it to say:

strSql = strSql & " AND R.FORUM_ID = F.FORUM_ID AND F.F_MODERATION in (1,3,9)" & " AND R.R_STATUS > 1 "


Step: 5
File: post.asp
Lines: 1045 - 1048
Find the following lines:

	      		if ForumModeration = 3 then
		     		Response.Write 	" selected "
	  		end if
	  		Response.Write 	" value=""3"">Replies Only Moderated</option>" & vbNewLine

After them, add the following lines:

	  	Response.Write 	"             	<option"
	      		if ForumModeration = 9 then
				Response.Write 	" selected "
			end if
			Response.Write 	" value=""9"">Moderate New User Posts Only </option>" & vbNewLine


Step: 6
File: post_info.asp
Lines: 309-323
Find the following lines:

		if MethodType <> "Forum" then
			'## Moderators and Admins are not subject to Moderation
			if strModeration = 0 or mlev = 4 or chkForumModerator(Forum_ID, strDBNTUserName) = "1" then
				Moderation = "No"
			'## Is Moderation allowed on the category?
			elseif CatModeration = 1 then
				'## if this is a topic, is forum moderation set to all posts or topic?
				if (ForumModeration = 1 or ForumModeration = 2) and (MethodType = "Topic") then
					Moderation = "Yes"
				'## if this is a reply, is forum moderation set to all posts or reply?
				elseif (ForumModeration = 1 or ForumModeration = 3) and (MethodType <> "Topic") then
					Moderation = "Yes"
					Moderation = "Yes"
				end if
		  end if
	   end if

Change them to read:

		if MethodType <> "Forum" then
			'## Moderators and Admins are not subject to Moderation
			if strModeration = 0 or mlev = 4 or chkForumModerator(Forum_ID, strDBNTUserName) = "1" then
				Moderation = "No"
			'## Is Moderation allowed on the category?
			elseif CatModeration = 1 then
				'## if this is a topic, is forum moderation set to all posts or topic?
				if (ForumModeration = 1 or ForumModeration = 2) and (MethodType = "Topic") then
					Moderation = "Yes"
				'## if this is a reply, is forum moderation set to all posts or reply?
				elseif (ForumModeration = 1 or ForumModeration = 3) and (MethodType <> "Topic") then
					Moderation = "Yes"
				elseif (ForumModeration = 9) and (numMPostCount <= clng(intRankLevel0)) then
					Moderation = "Yes"
				end if
		  end if
	   end if


Step: 7
File: pop_help.asp
Lines: 149
Find the following line:

" <b>Replies Only Moderated:</b> This option allows you to moderate only the replies that are posted to the forum. New topics are not moderated.<br /><br />" & vbNewLine & _

After it, add the following line:

" <b>Moderate New User Posts Only:</b> With this option, the posts made by New Members only will need to be moderated.<br /><br />" & vbNewLine & _ 

Note: Make sure the above statement is on one line only.

Edited by - Carefree on 15 April 2008 20:10:23
Go to Top of Page

MaD2ko0l
Senior Member

United Kingdom
1053 Posts

Posted - 15 April 2008 :  21:13:14  Show Profile  Visit MaD2ko0l's Homepage
you forgot the addition that dayve has posted a bit futher down the post abotu inc_moderation

© 1999-2010 MaD2ko0l
Go to Top of Page

Carefree
Advanced Member

Philippines
4207 Posts

Posted - 15 April 2008 :  21:15:53  Show Profile
You mean the one at step 4? I reordered them to keep the files in alphabetic order.
Go to Top of Page

MaD2ko0l
Senior Member

United Kingdom
1053 Posts

Posted - 16 April 2008 :  10:06:08  Show Profile  Visit MaD2ko0l's Homepage
ah, didnt notice it there ;-)

© 1999-2010 MaD2ko0l
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.38 seconds. Powered By: Snitz Forums 2000 Version 3.4.07