Skip to:
Content
Pages
Categories
Search
Top
Bottom

Force users to sign up before being able to see content/members

  • Avatar of do77
    do77
    Participant

    @do77

    Hi,

    I am new to buddypress and although its quite easy to understand I am struggeling with the following:

    Right now, everyone (even non-registered users) can go to my homepage and search for members and see recent activity etc. How do I block everyone from doing that and force them to sign up?

    I appreciate any help!

    Thanks,

Viewing 13 replies - 1 through 13 (of 13 total)
  • Avatar of Brajesh Singh
    Brajesh Singh
    Participant

    @sbrajesh

    well, this should help you. You need the privacy component.

    Check out Jeff’s privacy component here

    http://jeffsayre.com/2009/12/05/buddypress-privacy-component-released/

    Avatar of do77
    do77
    Participant

    @do77

    Thanks Brajesh! That seems like what I was looking for :)

    Avatar of do77
    do77
    Participant

    @do77

    So I installed the plugin but it does not seem to work properly. It created a new tab for navigation link Buddypress called ‘Privacy Settings’ but when I click on that link to open the site I get an ‘Page not found error’.

    I have noticed that every page under the same tab (Buddypress) looks like

    e.g. mydomain.com/wp-admin/admin.php?page=bp-general-settings

    but the Privacy Page tries to open like this:

    mydomain.com/wp-admin/bp-privacy-settings

    Has anyone had the same problem? Or does someone know how to fix it or what the reason could be?

    Thanks!!

    Avatar of do77
    do77
    Participant

    @do77

    For people that might have the same problem … the privacy component only works up to wpmu version 2.8.6

    Avatar of Mike Pratt
    Mike Pratt
    Participant

    @mikepratt

    @do77 It also does not work in 1.2 Let us know what versions (WPMU, BP, etc) you are working with so we can better guide you

    Avatar of Maxisnow
    Maxisnow
    Participant

    @maxisnow

    I’m in the same boat as @do77 here.

    I’m looking to add a login for all content at my buddypress instance.

    I, however, am running WordPress 2.9.1 (single) and the Buddypress trunk (I update once a week)

    I have the “Force User Login” plugin for WordPress currently running, but you can still navigate around it if you try via direct URL requests and the like.

    Any solid solutions?

    Avatar of Peterverkooijen
    peterverkooijen
    Participant

    @peterverkooijen

    I use this as temporary solution:

    function js_restrict_access(){
    global $bp, $bp_unfiltered_uri;

    if (!is_user_logged_in() &&
    (BP_MEMBERS_SLUG == $bp_unfiltered_uri[0] ||
    BP_GROUPS_SLUG == $bp->current_component ||
    BP_BLOGS_SLUG == $bp->current_component)){

    bp_core_redirect( get_option('home') . "/register" );

    }
    }
    add_action( 'wp', 'js_restrict_access', 3 );

    It closes the members, groups and blogs sections for non-registered users. You have to put it in bp-custom.php.

    Privacy is planned for a later version, maybe, or maybe not.

    Avatar of Tore
    Tore
    Participant

    @toregus

    Hi Peter!

    Is it possible to also include “activity” (the stream) from Buddypress 1.2 in this? That way, you’d cover most things.

    Thanks!

    Tore

    Avatar of stripedsquirrel
    stripedsquirrel
    Participant

    @stripedsquirrel

    You probably could use one of the “members only” plugins and adapt them. I do not use them myself, but know they can be used to hide content. You can use it in the loop or maybe for other templates as well to hide more?

    Avatar of Tore
    Tore
    Participant

    @toregus

    Hi!

    Thanks for the suggestion. I’ve been using a header-hack to ensure that no non-registrees are allowed into the website. I’ve only found http://wordpress.org/extend/plugins/registered-users-only-2/ that’s secure enough for me (all parts of the website). But it isn’t supporting BP 1.2. right now. I’m hoping for a release soon enough although.

    Avatar of Jehy
    Jehy
    Participant

    @jehy

    Hello. I just corrected registered-users-only, and it sould work fine with buddypress :)

    Your tests and feedback are welcome:

    http://wordpress.org/extend/plugins/registered-users-only-2/

    Avatar of stwc
    stwc
    Participant

    @stwc

    Thanks, Jehy, Just what I was looking for.

    Avatar of Gene53
    Gene53
    Participant

    @gene53

    Being that I do want my front page to show, I used Peterverkooijen code and added:

    BP_ACTIVITY_SLUG == $bp->current_component ||

    so guests can’t access the activity stream.

    The last thing I’d like to accomplish is to modify:

    bp_core_redirect( get_option('home') . "/register" );

    to a page which would read “You have stumbled upon a Member’s only area. Please login or register”

    I have created such a page and changed the redirection to it but the only caveat is that the page title appears in the top menu.

    Is there a way to get around this?

    Thanks,

    Gene

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

You must be logged in to reply to this topic.