Forums

Join
bbPress Support ForumsPluginsAnnouncement Forum

Info

Announcement Forum

  1. Hi all,
    I'm looking to create an announcement forum so I can post announcements for my site.
    For this forum, I'd like it so only moderators+ can start topics but anyone can respond to a topic.
    Does anyone know of a plugin that would add this ability?

    Many thanks.

  2. WordPress does this.

  3. This plugin should allow you to restrict who can post into a particular forum:
    http://bbpress.org/plugins/topic/read-only-forums/

    I use it on one of my sites, and it works great!

  4. Thanks jonhiler. Problem is, this seems a tad buggy.
    I've restricted a forum so no one but moderators+ can post in it, but at the bottom of the forum theres still: "New Topic in this Forum" for users. How can I remove this?
    I also get errors like this:
    Warning: in_array() expects parameter 2 to be array, null given in /forum/my-plugins/read-only-forums.php on line 62

  5. What version of bbPress are you using? The plugin may not be compatible with version 1.0...

    Also - what edits did you make to the settings section of the admin?

  6. I'm running 1.0.2. I didn't make any edits to the settings section of the admin as the instructions didn't say to do so.

  7. The instructions in the readme file should mention the settings?

    * Until an admin menu is created, edit read-only-forums.php and change settings near the top as desired
    * Add the read-only-forums.php file to bbPress' my-plugins/ directory and activate.

    http://bbpress.org/plugins/topic/read-only-forums/installation/

  8. Oh sorry, I thought you meant settings within the admin panel. Yes, I've edited the script and edited the templates as instructed.

    global $read_only_forums,$bb_current_user, $bb_roles;

    // edit users (and forums) by NUMBER below until an admin menu can be made

    //$read_only_forums['deny_all_start_topic']=false; // true = stop ALL members from starting topics in ALL forums
    //$read_only_forums['deny_all_reply']=false; // true = stop ALL members from replying to topics in ALL forums

    $read_only_forums['deny_forums_start_topic']=array(5); // which forums should ALL members NOT be able to start topics
    //$read_only_forums['deny_forums_reply']=array(9,15,22); // which forums should ALL members NOT be able to reply to posts

    //$read_only_forums['allow_members_start_topic']= array(1=>array(1,2,3,4,5,6,7), 2=>array(9,10,11)); // allow override for this member=>forums
    //$read_only_forums['allow_members_reply']= array(1=>array(1,2,3,4,5,6,7), 2=>array(9,10,11)); // allow override for this member=>forums

    //$read_only_forums['deny_members_start_topic']= array(54321=>array(1,2,3,4,5,6,7), 34567=>array(1,2,3)); // deny this specific member=>forums
    //$read_only_forums['deny_members_reply'] = array(54321=>array(1,2,3,4,5,6,7), 34567=>array(1,2,3)); // deny this specific member=>forums

    $read_only_forums['allow_roles_always']=array('moderator','administrator','keymaster'); // these types of users can always start/reply

    $read_only_forums['message_deny_start_topic']=__("Sorry, only moderators can start topics in this forum.");
    $read_only_forums['message_deny_reply'] = __("Posting in this topic has been restricted.");

    // stop editing here

  9. Ah ok. The only thing I can think of is that I might be careful about commenting out some of those lines... but instead, put in forum numbers that you know won't be an issue. That's total speculation though.

    Either way, I wouldn't comment out those two lines at the top of the settings:

    '//$read_only_forums['deny_all_start_topic']=false; // true = stop ALL members from starting topics in ALL forums'
    '//$read_only_forums['deny_all_reply']=false; // true = stop ALL members from replying to topics in ALL forums'

    If that doesn't work, it's probably a compatibility issue - _ck_ has mentioned that she's not updating a lot of her plugins for version 1.0 until December or so...

  10. Yay, thanks John, I set all the arrays to really high numbers and that eliminated the errors. But I still have "New Topic in this Forum" even when the user is unable to start a topic. You wouldn't know how to get rid of that would you? I can't seem to find it in the templates, perhaps I'm looking in the wrong place.

  11. Try something like this?

    <?php if ( bb_current_user_can( 'write_topic' ) ) { new_topic(); } ?>

  12. You must log in to post.