Skip to:
Content
Pages
Categories
Search
Top
Bottom

key master only forum


  • dragosbogdan
    Member

    @dragosbogdan

    I’m using bbpress for my online class and I would like to create a forum that only I or a moderator can post to, and the students (members) can view only.

    I’ve seen plug-ins to make forums private, but that’s not exactly what I need. Can someone point me in the right direction?

    Thanks

Viewing 5 replies - 1 through 5 (of 5 total)

  • _ck_
    Participant

    @_ck_

    This will affect all forums:

    global $bb_roles;
    $bb_roles->remove_cap('member','write_topics');
    $bb_roles->remove_cap('member','write_posts');

    You can put it into header.php or make a real plugin ie.

    members-cannot-post.php (and install into /my-plugins/)

    <?php
    /*
    Plugin Name: Members Cannot Post
    */
    global $bb_roles;
    $bb_roles->remove_cap('member','write_topics');
    $bb_roles->remove_cap('member','write_posts');
    ?>

    I think I will make a real plugin which can control this on a per-forum basis since this seems to be a requested feature that is not too hard to handle in 0.9 Look for it in the plugin section over the next day or two.

    a plugin sounds great ck. I for one would definitely benefit from it.

    not so easy to implement it seems:

    Fatal error: Call to a member function remove_cap() on a non-object in /var/www/vhosts/…/httpdocs/forums/my-plugins/nopost.php on line 8


    _ck_
    Participant

    @_ck_

    I’ve now written a plugin to solve this problem:

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


    dragosbogdan
    Member

    @dragosbogdan

    great plugin _ck_, thanks a bunch.

Viewing 5 replies - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.