Page 1 of 16

Approval MOD

Posted: Sun Sep 17, 2006 2:31 am
by Extensions Robot
Modification name: Approval MOD
Author: uncle.f
Modification description: This MOD makes it possible to prevent users from viewing the unapproved posts until the contents has been approved by the moderator(s). The MOD can be used to combat spam bots that make random posts in the public forums or for extended moderation in any forum with sensitive topics (religion, politics, etc.) where post screening is required to maintain forum integrity. The MOD is quite flexible in its settings and allows you to configure various approval options per forum.
Modification version: 2.0.0
Tested on phpBB version: See below

Download file: approval_mod_2.0.0.zip
File size: 20431 Bytes

Modification overview page: View


Selected tags:
  1. category
    1. Add-Ons
  2. phpbb
    1. 2.0.21
    2. 2.0.22
Support for this modification needs to be asked within this topic. The phpBB Team is not responsible or required to give anyone support for this modification. By installing this MOD, you acknowledge that the phpBB Support Team or phpBB MODifications Team may not be able to provide support.

This MOD has only been tested by the phpBB MOD Team with the phpBB version listed in the topic. It may not work in any other versions of phpBB.

Posted: Fri Oct 20, 2006 12:04 pm
by ycl6
MOD Validated/Released

Notes:
With this MOD, users' posts can be moderated before viewable by other members.

Posted: Mon Oct 23, 2006 8:05 am
by uncle.f
Some more useful links:

FAQ / Readme First: Link

Detailed Info / Documentation: Link

Demo Board: Link
Demo Usernames: user or user2 for an ordinary user, mod for a moderator, admin for an admin
Demo Passwords: same as the user names

Posted: Mon Oct 23, 2006 3:25 pm
by igorw
Looks very impressive! I havn't looked at the code, but judging from the screenshots, this looks very powerful!

Posted: Mon Oct 23, 2006 3:38 pm
by uncle.f
Thanks!

This MOD is not really a lot of code. I am currently developing this MOD further into another one that will allow approval by groups. See the info in this topic.

Posted: Thu Oct 26, 2006 5:03 pm
by Gregminimum
If I install the currently released Approval mod, and then when the new version (with approval by groups) comes, I try to install that one, will it be a simple process? Will the new one automatically replace the old one?

Posted: Thu Oct 26, 2006 10:41 pm
by uncle.f
To make this MOD "upgradable" to the Approval Groups MOD will mean additional development. I never planned this, to be honest. Approval Groups MOD is really another MOD there is a lot of new code in it and the code from this MOD is not really used one-to-one. So I would say treat them as two completely different MODs.

Posted: Thu Oct 26, 2006 11:22 pm
by Gregminimum
OK, I'll wait for the Approval Groups MOD. Please let me know.

Posted: Sun Oct 29, 2006 8:32 pm
by Gregminimum
After installation of the Approval MOD, can it be uninstalled, and then the Approval Groups MOD be installed without problems?

Posted: Mon Oct 30, 2006 8:55 am
by uncle.f
Gregminimum wrote: After installation of the Approval MOD, can it be uninstalled, and then the Approval Groups MOD be installed without problems?


If you made a backup of all modified files (EasyMOD does this for you, for instance) AND you have not installed any mods after the Approval MOD, then you can just replace the modified files later on, which will do a "rollback" for you. After that Approval Groups MOD can be installed without any problem.

There may be a couple of extra SQL commands needed too, but that should not be complicated (if you know how to execute SQL commands) :wink:

Posted: Mon Oct 30, 2006 11:48 pm
by Elias
Can this be configures that only a special group can approve the posts? and not moderators.

Posted: Tue Oct 31, 2006 9:10 am
by uncle.f
EY wrote: Can this be configures that only a special group can approve the posts? and not moderators.


At this stage - no. Maybe it will be eventually implemented in the Approval Groups MOD.

Posted: Fri Nov 17, 2006 7:13 pm
by x2k10
Hi, I was just wondering if it's possible to make this mod so that only new topics require approval and not every post?

Thanks in advance.

Posted: Fri Nov 17, 2006 8:17 pm
by uncle.f
I was just wondering if it's possible to make this mod so that only new topics require approval and not every post?

this in development now

Posted: Sun Nov 19, 2006 6:00 am
by acharabia
I think this MOD quite complicate which I like...
But there is error msg like below... Unfortuantely,
this mannual not very clearly or formal. So I can't
follow so easy along this mannual. Could you give
another mannual here?

Parse error: syntax error, unexpected T_RETURN in /..../includes/functions_post.php on line 484

Code: Select all

#-----[ FIND ]---------------------------------------------
#
$meta
$message

return false;
#
#-----[ BEFORE, ADD ]-----
#
	// approval mod
	$approve_hide = (($post_data['forum_approve'] & (APPROVE_ON|APPROVE_HIDE)) == (APPROVE_ON|APPROVE_HIDE)) ? TRUE : FALSE;
	$approve_warn = (($post_data['forum_approve'] & (APPROVE_ON|APPROVE_WARN)) == (APPROVE_ON|APPROVE_WARN)) ? TRUE : FALSE;



What's mean that?

Code: Select all

#
#-----[ IN-LINE FIND ]-----
#
. (($mode == 'newtopic') ? ", forum_topics = forum_topics $sign"
#
#-----[ IN-LINE BEFORE, ADD ]-----
#
 . ($post_data['approve'] == APPROVE_OFF ? ", forum_last_post_approved = $post_id" : '')
#
#-----[ IN-LINE AFTER, ADD ]-----
#
 . ($post_data['approve'] == APPROVE_ON ? ", forum_topics_unapproved = forum_topics_unapproved $sign" : '' )


This is viewforum.php... But there are already some editing in my file.
e.g. Global announcement, or topic-calendar... etc. How do I do?
So I got a problem about this MOD.

Code: Select all

#
#-----[ FIND ]---------------------------------------------
#
$sql
FROM
WHERE
AND
AND
AND
AND t.topic_type = " . POST_ANNOUNCE
ORDER
#
#-----[ BEFORE, ADD ]-----
#
// sql replaced by approval mod
#
#-----[ REPLACE WITH ]-----
#
$sql = "SELECT t.*, u.username, u.user_id, u2.username as user2, u2.user_id as id2, p.post_username, p2.post_username AS post_username2, p2.post_time, p2.post_approve
	FROM " . TOPICS_TABLE . " t, " . USERS_TABLE . " u, " . POSTS_TABLE . " p, " . POSTS_TABLE . " p2, " . USERS_TABLE . " u2
	WHERE t.forum_id = $forum_id
		AND t.topic_poster = u.user_id
		AND p.post_id = t.topic_first_post_id
		AND p2.post_id = $sql_approve_where
		AND u2.user_id = p2.poster_id
		AND t.topic_type = " . POST_ANNOUNCE . "
	ORDER BY $sql_approve_order";