What exactly do I need to do this...

I have a site which I am working on configured as a WP 3.1 multi site (sub dir) with buddypress included.

I would like to have (unregistered) visitors be able to view pretty much all content published.
Allow visitors to create an account within buddypress (free)
Allow only registered users to sign up/create a blog (free)

Once they've signed up, for the blog I want to be able to remove the majority of the admin menu's with a few exceptions, examples below...

-Dashboard (available)
-Posts (hidden/inaccessible)
-Media (available)
-Links (available)
-Pages (hidden/inaccessible)
-Comments (hidden/inaccessible)
-Appearance (hidden/inaccessible)
-Plugins (hidden/inaccessible)
-Users (hidden/inaccessible)
-Tools (hidden/inaccessible)
-Settings (hidden/inaccessible)
-My Created Post Types/Taxonomies (available)

As you can see, I basically want to strip down the admin area for each and every user created blog. I've already installed Membership Premium. But I am running into some difficulty/confusion while trying to configure it.

First of all I don't actually want to charge a fee for this, is Membership Premium the right tool for this job?

  • Scott
    • Flash Drive

    I tried that one and was very impressed with it, up until I ran into problems with it allowing access to Custom Post Types in the admin menu. But it is clearly by far the easiest to use and setup in comparison to the other rivals out there.

    However, in the post you linked one of the members mentioned about WPMUDev Membership Premium's feature to do this. However, The problem I'm experiencing is that when a user registers for a blog, the user for the blog is created and managed within the network Admin.

    The Membership plugin is giving me some trouble, I've attached some screenshots. It seems like Membership is seeing the user in some cases and not others.

    It seems like the user is being registered on the default blog, but the user is actually being created in the Network Admin area and not the default blog within Membership...

    Any idea's?

  • Shawn
    • The Crimson Coder

    Hi, Scott! By default, users that signup are not automatically assigned to a blog unless they request one. What you're going to want to do is ensure that they are, in fact, assigned to the home blog. This should work to add the user to your home blog on signup:

    function scotts_new_user($blog_id, $user_id) {
      global $current_site;
      add_user_to_blog( $current_site->blog_id, $user_id, 'subscriber' );
    add_action( 'wpmu_new_blog', 'scotts_new_user', 10, 2 );

    If you want to add them to a specific blog, you can use this (change 42 to the blogid):

    function scotts_other_new_user($blog_id, $user_id) {
      add_user_to_blog( '42', $user_id, 'subscriber' );
    add_action( 'wpmu_new_blog', 'scotts_other_new_user', 10, 2 );

    You can also change "subscriber" to whatever role you want to assign.

  • DavidM
    • DEV MAN’s Mascot

    Thanks for that tidbit Shawn! Had to throw some more rep points your way. This helpful community will have all my rep points soon enough!

    Heya Scott, were you having some specific trouble regarding custom post types with Membership? I've actually used the Menu rules to restrict access to the custom post type menus myself. And if needed, I'll go ahead and use URL Group rules to restrict access to the urls used for creating/editing custom post types. I'd love to delve into that one if you have any questions on that!


Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.