[Dev] Forum Topics/Posts Approve mod

A place for MOD Authors to post and receive feedback on MODs still in development. No MODs within this forum should be used within a live environment! No new topics are allowed in this forum.
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

IMPORTANT: MOD Development Forum rules

On February 1, 2009 this forum will be set to read only as part of retiring of phpBB2.
AceMan
Registered User
Posts: 337
Joined: Thu Nov 15, 2001 6:47 am
Contact:

[Dev] Forum Topics/Posts Approve mod

Post by AceMan »

UPDATED 02/14/02!
http://www.phpbb.com/phpBB/viewtopic.php?t=76852


3.0.0b2 BETA: DOWNLOAD BETA

This thread is the revisit discussions regarding the:
Approve MOD

Project re-Start Date: Jan 13, 2003
Anticipated Release v3.0: Feb 15, 2003
project setback to feb 15th due to systems failures & development environment rebuild (aka, my computers crashed)

References (desc by date):

http://www.phpbb.com/phpBB/viewtopic.php?t=43283
http://www.phpbb.com/phpBB/viewtopic.php?t=13962
http://www.phpbb.com/phpBB/viewtopic.php?t=13859

DEMO:
http://phpbb.aceman.dyndns.org:8000/

admin user:-----------------------------------normal user:

username: admin ------------------------------ someuser
pass: approve ------------------------------ password

It appears it would be best for me to almost COMPLETELY rewrite this mod. SO - Please post your contributions & suggestions for added features for this mod.

TASK LIST/HISTORY: (to be appended)

02/02/03 done - create 2 tables, 1 for forum options, 1 for posts/threads
02/02/03 done - create forum option controls in admin panel
02/02/03 done - create entries in database during thread/post posts if forum is set for approval
02/02/03 done - create admin links for: approve topic, approve post
02/02/03 done - create links for approve all current posts in this topic, approve this topic and all future posts
02/02/03 done - create admin links for: auto-approve user, remove auto approval, moderate user, remove moderation
02/10/03 done- create admin email or pm notification option in admin panel
- on new topic, or reply, notify user they'll be 'moderated'

new enhancements to be put in:
admin forum page:

approve posts:
02/02/03 done. for all users
02/10/03 done. for moderated users

approve topics:
02/02/03 done. for all users
02/10/03 done. for moderated users

approve post edits:
02/10/03 done. for all users
02/10/03 done. for moderated users

approve topic edits:
02/10/03 done. for all users
02/10/03 done. for moderated users

admin notification:
02/10/03 done. notify user: (user search field will put in name using popup like phpBB)
02/10/03 done. notify method:
02/10/03 done ---- .email
02/10/03 done ---- .pm
02/10/03 done. notify on:
02/10/03 done ---- .new posts needing moderation
02/10/03 done ---- .new topics needing moderation
02/10/03 done ---- .edited posts needing moderation
02/10/03 done ---- .edited topics needing moderation
02/13/03 done -notify user their post was 'approved'
02/13/03 done -notify user on posting that they'll be moderated
02/13/03 done -maybe - 'mark this thread for moderation'

issues to address:
admin/moderator control panel page for all topics, users, posts & moderation control. Seperate file add-on.

issues that won't be addressed:
'Mark all topics read'

sudoCVS Source:

Will be updated. This code is not RELEASE version. USE ONLY ON TESTING PLATFORMS!
Forum Topic/Posts Approve MOD

02/13/03 -LINK CONTAINS NEW INFO
post is too long, breaks forums, please view link for MOD!
Last edited by AceMan on Fri Feb 14, 2003 5:38 am, edited 44 times in total.
User avatar
GoleyC
Registered User
Posts: 374
Joined: Thu Mar 14, 2002 5:22 pm
Location: Ohio
Contact:

Post by GoleyC »

I've complied a list of things that will need to be addressed in the latest update/fix for Topics/Post Approve MOD

Here are the list of things that need to be addressed:
  1. Auto-pruning gets broken. The "Remove topics that have not been posted to in" and "Check for topic age every" do not popluate with the current numbers from the database if they have been changed from the defaults. They resort back to the defaults of 7 and 1. However, you can update and still run auto-prune, it's just that the correct numbers are never pulled from the database.
  2. This was added to topic_review topic and doens't work, errors out.

    Code: Select all

    ADDED AFTER WORKING COPY 
    /phpBB2/includes/topic_review.php
    
    
    # 
    #-----[ FIND ]------------------------------------------------------- 
    # approx line: 117 - 120 
       // 
       // Okay, let's do the loop, yeah come on baby let's do the loop 
       // and it goes like this ... 
       //
    
    
    # 
    #-----[ BEFORE, ADD ]------------------------------------------------ 
    # approx line: 116 
    // Begin Approve Posts
    $sql = "SELECT * FROM " . APPROVE_POSTS . " WHERE forum_id = $forum_id"; 
    if ( !($result = $db->sql_query($sql)) ) 
    { 
       message_die(GENERAL_ERROR, 'Could not obtain forum approval information', '', __LINE__, __FILE__, $sql); 
    } 
    if ( $row = $db->sql_fetchrow($result) ) 
    {    
          $sql = "SELECT * FROM " . APPROVE_POSTS . " WHERE topic_id = $topic_id"; 
          if ( !($result = $db->sql_query($sql)) ) 
          { 
             message_die(GENERAL_ERROR, 'Could not obtain topic approval information', '', __LINE__, __FILE__, $sql); 
          } 
          if ( $row = $db->sql_fetchrow($result) ) 
          { 
             if ( $row['topic_id'] != 0 ) 
             { 
                $approve_posts_enabled = True; 
             } 
          } 
    } 
    if ( $is_auth['auth_mod'] ) 
    { 
       $approve_posts_enabled = False; 
    } 
    // End Approve Posts
  3. In File: viewtopic.php submitted by "forget who I'll grab that name shorty" fixes replies 2 pages deep getting approved.

    Code: Select all

    // Begin below code for replies 2 pages deep approval link fix
    if (isset($HTTP_GET_VARS['approve_topic'])) 
    { 
    $approve_topic = intval($HTTP_GET_VARS['approve_topic']); 
    } 
    if (isset($HTTP_GET_VARS['approve_post'])) 
    { 
    $approve_post = intval($HTTP_GET_VARS['approve_post']); 
    }
    // End above code for replies 2 pages deep approval link fix
This should do it for right now. I might have more once I take another look at it and do more code crunching.
CG
AbelaJohnB
Former Team Member
Posts: 5674
Joined: Fri Jul 06, 2001 11:56 pm

Post by AbelaJohnB »

/me thinks this is very interresting :) Will be neat to see/try when it makes final version. :mrgreen:
User avatar
GoleyC
Registered User
Posts: 374
Joined: Thu Mar 14, 2002 5:22 pm
Location: Ohio
Contact:

Post by GoleyC »

OK..I've done some other thinking about this MOD. Here is additional ideas to either go with our think about.

Ideas:
1: The ability to select which post get moderated. For example, someone post a topic that you would like to monitor and approve only new post after that. Then only this post gets stamped as one that needs approval before any new post show up. So if someone replies to this post, then that post needs approved before it will show up.

The reverse of this should be true to, once you a confortable with additional post, you can then unstamp this topic and no more post will be moderated.
2: To be able to moderate only certain members too.


Enhancement:
With the above idea, it would be awful to see post go unapproved for a long time. Therefore, it would be nice to see an email dispatched to the moderators to alert them of this new post that needs to be approved.

This dispatched email could be carried over to all forums that require approval, as it would be very hard to monitor many post/forums if you have over 20 that could contain well over 100 post a day each in them that might need to be approved.
CG
tallis
Registered User
Posts: 8
Joined: Fri Dec 07, 2001 3:45 am

Bug in this version of phpBB

Post by tallis »

Use "quote" instead of code; seems to be a bug in the "code" bbcode implementation. I believe that "quote" will work.
AceMan
Registered User
Posts: 337
Joined: Thu Nov 15, 2001 6:47 am
Contact:

Post by AceMan »

had a systems crash that set me back a week.. check back for updates soon...


check first post, click demo url, for what functionality it's setup, it's fully functional!

now to add more features..
AceMan
Registered User
Posts: 337
Joined: Thu Nov 15, 2001 6:47 am
Contact:

Post by AceMan »

GoleyC wrote: 1.Auto-pruning gets broken. The "Remove topics that have not been posted to in" and "Check for topic age every" do not popluate with the current numbers from the database if they have been changed from the defaults. They resort back to the defaults of 7 and 1. However, you can update and still run auto-prune, it's just that the correct numbers are never pulled from the database.




? Please give details.. I wanna be lazy for once :)

I havn't looked at the auto-pruning features yet, nor do I see how this mod would muck w/ that, but I do see how the mod could PREVENT un-approved posts from being dumped by prune, or if pruned, delete the approval info
AceMan
Registered User
Posts: 337
Joined: Thu Nov 15, 2001 6:47 am
Contact:

Post by AceMan »

GoleyC wrote: 1: The ability to select which post get moderated. For example, someone post a topic that you would like to monitor and approve only new post after that. Then only this post gets stamped as one that needs approval before any new post show up. So if someone replies to this post, then that post needs approved before it will show up.

The reverse of this should be true to, once you a confortable with additional post, you can then unstamp this topic and no more post will be moderated.

check out the demo, does it satisfy these ideas?
GoleyC wrote: 2: To be able to moderate only certain members too.

i'll be adding a feature like this, and more in the next answer..
GoleyC wrote: With the above idea, it would be awful to see post go unapproved for a long time. Therefore, it would be nice to see an email dispatched to the moderators to alert them of this new post that needs to be approved.

This dispatched email could be carried over to all forums that require approval, as it would be very hard to monitor many post/forums if you have over 20 that could contain well over 100 post a day each in them that might need to be approved.

in order to provide the BEST functionality, I'm going to add an add-on admin/moderator control panel. Admins&Mods can login & view all posts requiring moderation, manage moderated users, and anythign else we can think of...
User avatar
GoleyC
Registered User
Posts: 374
Joined: Thu Mar 14, 2002 5:22 pm
Location: Ohio
Contact:

Post by GoleyC »

Hi Aceman,

Glad to see you back and with an update to your MOD above.

Here are current issues that I don't know if you plan on addressing them or these will not be addressed.
  1. Admin needing not to approve of their own post
  2. Given certain moderators the ability to not have to approve of their own post.
  3. Given the link "[ Topic has posts awaiting approval ]" a different color or text size. Maybe do something like this: "[ Topic has posts awaiting approval ]" Make the link the same "class" as the Forum "Topics, Replies, Author, Views, Last Post" row.
  4. Plus additional enhancement when you click on the "[ Topic has posts awaiting approval ]" it takes you to the first post that needs approval. This way you do not have to scroll through the topic to find that post.
So far so good!
CG
AceMan
Registered User
Posts: 337
Joined: Thu Nov 15, 2001 6:47 am
Contact:

Post by AceMan »

the only existing css style w/ different links is copyright...

i used that one for now.

admin's gotto approve his own posts right now for ease of design, not having to log in & out 100 times..

:)
AceMan
Registered User
Posts: 337
Joined: Thu Nov 15, 2001 6:47 am
Contact:

Post by AceMan »

REQUEST:

Image buttons to replace all current link text. Some are topic view, some are forum view. Goto demo URL & login as admin to see current link placement. Small images can be used, a key will be implemented at the bottom of the topic view.

$lang['approve_topic_has_awaiting'] = 'Topic has posts awaiting approval';
$lang['approve_topic_is_awaiting'] = 'Topic is awaiting approval';
$lang['approve_post_is_awaiting'] = 'Post is awaiting approval';

$lang['approve_post_approve'] = 'Approve this post';
$lang['approve_topic_all_current'] = 'Approve all current posts in this topic';
$lang['approve_topic_all_future'] = 'Auto-Approve all future posts in this topic';
$lang['approve_topic_all_future_rem'] = 'Remove Auto-Approve of all future posts in this topic';

$lang['approve_post_user_approve'] = 'Auto-Approve this user';
$lang['approve_post_user_approve_rem'] = 'Remove Auto-Approve';

$lang['approve_post_user_moderate'] = 'Moderate this user';
$lang['approve_post_user_moderate_rem'] = 'Remove Moderation';
AceMan
Registered User
Posts: 337
Joined: Thu Nov 15, 2001 6:47 am
Contact:

Post by AceMan »

:? ...


any1 still interested in this? otherwise this beta might as well be release..

post your feature suggestions
gwood80
Registered User
Posts: 7
Joined: Thu Feb 06, 2003 12:23 pm
Location: Glasgow

Post by gwood80 »

YES. I am interested.

Is it possible to set it up so that when a topic or message is waiting for approval, the moderator/admin get emailed?

Cheers
netclectic
Former Team Member
Posts: 4439
Joined: Wed Mar 13, 2002 3:08 pm
Location: Omnipresent
Contact:

Post by netclectic »

very interesting, i'll be watching the development of this one.
Look forward to the release :)
Defend the game:
Image
User avatar
GoleyC
Registered User
Posts: 374
Joined: Thu Mar 14, 2002 5:22 pm
Location: Ohio
Contact:

Post by GoleyC »

Yeap..we are still interested. As long as must of the features we suggested are implemented we'll be using this straight from the box.
CG
Locked

Return to “[2.0.x] MODs in Development”