bbPress Plugin Browser »

Hidden Forums (0.0.9)

Download

Version: 0.0.9

Last Updated: 2009-5-13

Requires bbPress Version: 0.9 or higher

Compatible up to: 0.9

Author Homepage »

Plugin Homepage »

Donate to this plugin »

Average Rating

5 stars
4 stars
3 stars
2 stars
1 star
(21)

Your Rating

Author: _ck_


  1. AnttiJN

    Member

    Hi ck and thanks for your fast reply. Im going to use bbpress as an administrator forum in a wordpress blog. The idea is to have a forum inside the WordPress administration area where admins and authors can discuss after logging in.

    I have plugin that creates a dashboard widget for the latest topics in bbpress and a custom linkbutton to the wp-admin menu for the forum. Furthermore I've created a bbpress theme that looks like the wp-admin theme. So an average user won't propably notice when he leaves the actual wp-admin -folder.

    Of course the bbpress installation itself is accessible for other users if they happen to guess the address. So by default I would like to hide all of the forums and grant permissions only to users who have at least the author role in wordpress.

    I also still need to disable the registration in the bbpress side, but that shouldnt be too hard.

    Posted: 3 years ago #
  2. vintageparisprincess

    Member

    Hi, I would like to try and use this plugin, but I don't understand how it works. I've set up a forum that I want to be private/hidden, and I want to add separate posts under that. I don't see the forum's name in the php file, and I don't understand what you mean in the php file - how do I label the forum (and the separate posts if necessary) as hidden? I am new to this whole structure, and it looks like I'm on version 0.9.0.4 thank you.

    Posted: 3 years ago #
  3. vintageparisprincess, add ?forumlist to the url of your forum and tell me what number is next to the forum you want to hide

    Let's say the number is 4

    So you'd edit near the top of hidden-forums.php and change
    $hidden_forums['hidden_forums']=array(500,501,502);
    to
    $hidden_forums['hidden_forums']=array(4);

    Then to give access to forum #4 you change this part

    $hidden_forums['allow_roles'][4]=array('administrator','moderator');	// exact formal role name, *not* ability
    $hidden_forums['allow_roles'][4]=array('administrator','moderator');	// exact formal role name, *not* ability

    or the lazy way
    $hidden_forums['allow_roles']['all_forums']=array('keymaster','administrator','moderator');

    Posted: 3 years ago #
  4. Works great for me. Thanks a heap.

    Posted: 2 years ago #
  5. Chris Grande

    Member

    _ck_ Thanks for the great plugin. I'm having trouble with .htaccess lines:

    RewriteRule ^topic(|/)$ /forums/ [R=302,L,QSA]
    RewriteRule ^forum(|/)$ /forums/ [R=302,L,QSA]

    My install is at the root of a sub domain I tried replacing /forums/ with just / and it didn't work. I get a message when I log out from a topic, the page says "Topic is not found". Logging out from a Forum page works. I'm using name based permalinks if that matters.

    Thanks!

    Posted: 2 years ago #
  6. Found a bug: the favourites rss still shows up. Tested on various computers. Do you see this? feed://kwlm.net/board/rss/profile/simon

    Posted: 2 years ago #
  7. thank you for reporting that zimen

    please try 0.0.6 when it appears shortly and see if the bug is fixed

    Posted: 2 years ago #
  8. Chris Grande

    Member

    I found my issue. I was using Options +MultiViews and it seems that your additions wouldn't work with that so I had bbPress generate the rewrite rules and I copied them in and removed the Options +MultiViews line. All is working! Only thing is the tag issue, but I can deal with that.

    Thanks for the great plugin!

    Posted: 2 years ago #
  9. I have finally come up with a very complicated scheme to get around bbpress's limitation of not filtering tags.

    update: wow it's working - will post soon

    Posted: 2 years ago #
  10. I've now posted (inside the plugin zip file) an experimental optional add-on
    for Hidden Forums to hide tags that belong to Hidden Forums.

    It makes no permanent changes so it's safe to try.

    Simply upload and activate hidden-forums-tag-filter.php
    There is no other editing or settings required (it gets them from the main plugin).

    Please let me know if it works for you.

    It should work on both bbPress 0.9 and bbPress 1.0

    Posted: 2 years ago #
  11. CK, 0.0.6 does not work for me. It does not even hide forums anymore! Had to revert back to the previous :)

    Edit: Sorry how dumb I forgot to set the options :)

    Posted: 2 years ago #
  12. Yeah you have to remember to copy over your options when you upgrade, sorry.

    I'll put in an admin menu in there eventually, I just don't like how they slow everything down.

    Posted: 2 years ago #
  13. Thank you for this plugin _ck_,

    I am using Vers. 0.0.6 and bbpress alpha-6.

    When hiding a forum, the forum name will still show up in the "Forums" list on the frontpage, though not accessible by the restricted user groups as expected.
    Is this intended and if it is, is there a way to hide it's existence altogether?

    Posted: 2 years ago #
  14. It should be hidden in the forum list, maybe Sam changed the filter name in alpha 6 which is why it stopped working.

    Technically I don't support anything after alpha 5 anymore but I will take a look at it later.

    update: I don't see any changes in alpha 6 like that, it should work, can anyone else confirm if it's working for them or not in 1.0 a6 ?

    Try changing around line 87

    from

    $filters=array(
    	'get_forums','get_topic','get_thread','get_thread_post_ids',

    to

    $filters=array(
    	'get_forum','get_forums','get_topic','get_thread','get_thread_post_ids',

    and see if that helps at all?

    Posted: 2 years ago #
  15. That did it for me _ck_, thanks again for the quick help.
    I was expecting some filter change since there seemed to be a lot of it since Alpha6.

    Posted: 2 years ago #
  16. I think what happened is that the newest bbpress preloads the forums and fetches them one by one.

    Posted: 2 years ago #
  17. fridaycafe

    Member

    Hi ck, thanks for the great plugin! I have an error while viewing forums when logged out. The error msg is:

    bbPress database error: [You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'WHERE forum_id NOT IN (2,3)' at line 1]
    SELECT * FROM bb_forums WHERE forum_id = 1 WHERE forum_id NOT IN (2,3)

    which probably comes from hidden_forums_filter function. Please help! (My server MySQL is: 5.0.67-community)

    Posted: 2 years ago #
  18. I'm getting the same error as fridaycafe. It's because the SQL query has two 'where' clauses in it. Not sure how to fix it yet though.

    EDIT: looks like the problem is afount line 100, with hidden_forums_filter(). It seems that the $where parameter isn't always provided when there is a where clause in the query, possibly from being added to the query improperly in a separate plugin or the core files.

    Posted: 2 years ago #
  19. I need to know what version of bbpress you are using and what other plugins.

    I suspect you are using 1.0 a6 ?

    My code tries to detect existing WHERE which may mean something is calling the filter without sending it's existing query, and just appending it afterwards which is the wrong behavior.

    Posted: 2 years ago #
  20. Please try 0.0.7 to fix the double WHERE on bbPress 1.0

    Posted: 2 years ago #

RSS feed for this topic

Add a Comment »

You must log in to post.