Page 1 of 1

How do I hide the s2Member plugin from child sites?

PostPosted: January 1st, 2011, 3:45 pm
by cdvrooman
Hello,
I'm using WP 3.0.3, BP 1.2.7 & s2Member 3.3.2 with Blog Farm and Open Registration enabled.

How can I prevent the s2Member admin menu from appearing in a sub-domain site's dashboard?

I've tried using the Exclude-Plugins: http://wordpress.org/extend/plugins/exclude-plugins, but s2Member still shows up.

Thanks,
Christopher.

Re: How do I hide the s2Member plugin from child sites?

PostPosted: August 9th, 2011, 7:55 pm
by banta
Hi Christopher,

Did you ever figure this out? I am looking to do the same thing.

Thank you,
Denis

Re: How do I hide the s2Member plugin from child sites?

PostPosted: August 10th, 2011, 11:03 am
by Cristián Lávaque

Re: How do I hide the s2Member plugin from child sites?

PostPosted: August 10th, 2011, 2:37 pm
by Jason Caldwell
cdvrooman wrote:Hello,
I'm using WP 3.0.3, BP 1.2.7 & s2Member 3.3.2 with Blog Farm and Open Registration enabled.

How can I prevent the s2Member admin menu from appearing in a sub-domain site's dashboard?

I've tried using the Exclude-Plugins: http://wordpress.org/extend/plugins/exclude-plugins, but s2Member still shows up.

Thanks,
Christopher.

By default, WordPress makes it possible to enable a plugin "Network Wide", or on per-Blog basis. So if you only need s2Member on one specific Blog in your Network, you can choose NOT to enable it Network Wide, and instead only enable it on the Blog(s) you need it on.

All of that being said, I realize the flexibility provided by a default installation of WordPress is probably not dynamic enough for some situations. This is really a WordPress limitation though, and not so much an s2Member limitation. Until WordPress makes this possible, I recommend one of these plugins for cases where you need greater flexibility:
http://wordpress.org/extend/plugins/plugins-enabler/
http://wordpress.org/extend/plugins/exclude-plugins/
http://wordpress.org/extend/plugins/res ... e-plugins/
http://wordpress.org/extend/plugins/plu ... -networks/

Re: How do I hide the s2Member plugin from child sites?

PostPosted: August 10th, 2011, 4:06 pm
by Cristián Lávaque
Jason Caldwell wrote:So if you only need s2Member on one specific Blog in your Network, you can choose NOT to enable it Network Wide, and instead only enable it on the Blog(s) you need it on.


How is this done?

Re: How do I hide the s2Member plugin from child sites?

PostPosted: August 10th, 2011, 4:44 pm
by Jason Caldwell
You place s2Member into your plugins directory. On the Main Site of your Network, in the Network Admin panel, do NOT click "Activate Network Wide". Instead, go to the Site Admin panel for a particular Blog and activate s2Member there, so it's only active on specific Blogs that you choose to use it on.

Re: How do I hide the s2Member plugin from child sites?

PostPosted: August 10th, 2011, 6:12 pm
by Cristián Lávaque
Ah, thanks. But can that be done by the child-blog admin or only by the network admin?

Re: How do I hide the s2Member plugin from child sites?

PostPosted: August 10th, 2011, 6:48 pm
by Jason Caldwell
Cristián Lávaque wrote:Ah, thanks. But can that be done by the child-blog admin or only by the network admin?
Yes, activating a plugin Network Wide, makes that plugin available and active across on Blogs in the Network. Not activating the plugin Network Wide, allows the plugin to be activated on a per-Blog basis, but there is no distinction between *who* actually owns the Child Blog ( i.e. the Super Admin, or just a Child Blog owner on a Multisite Blog Farm ). This is where a Multisite Network administrator might find a use for one of these other plugins, one of which may provide more fine tuning to allow/deny access based on Role, Capability, or possibly based on the ID of a Blog itself.

Currently, s2Member can be activated Network Wide, where it becomes active on all Child Blogs of the Network. Or, you can choose NOT to enable it Network Wide. In this case, s2Member can be activated at will, on a per-Blog basis, so long as the "plugins" menu box is checked in your WordPress Networking configuration, under the Network Admin panel for WordPress itself.

This is under: WordPress -> Network Admin -> Plugins
( allowing s2Member to be activated for ALL sites in the Network )
network-enable-s2.png
network-enable-s2.png (12.56 KiB) Viewed 2009 times


Or, alternatively: WordPress -> Site Admin -> Plugins
( to activate s2Member only for specific Blogs in the Network )
site-activate-s2.png
site-activate-s2.png (10.08 KiB) Viewed 2009 times


This is under: WordPress -> Network Admin -> Network Settings:
( allowing all Child Blog owners access to the plugins menu for their instance of WordPress )
network-plugins.png
network-plugins.png (31.13 KiB) Viewed 2009 times

If this is enabled ( i.e. the box is checked ), and Network Activation has NOT taken place, a Child Blog owner would still be able to activate s2Member on their own, simply because it's installed on the Network, and because they DO have access to the Plugins Menu in their instance of WordPress, as dictated by this checkbox.

If this is NOT enabled, they would NOT be able to, because they have no access to the Plugins Menu panel in their instance of WordPress anyway; so they are left at the mercy of the Network Administrator, with whatever configure the Network Admin has provided them with ( i.e. they MAY not configure plugins ).

If/when the Plugins menu IS enabled, and s2Member IS installed, AND you want to have specific control over *which* Child Blogs in the Network have access to s2Member, you will need help from another plugin that allows for such a thing. Giving you the ability to dictate which specific Child Blogs in the Network will have access to use s2Member on their instance of WordPress. This is not something that WordPress makes possible on its own, and s2Member does not provide this feature yet either.

Re: How do I hide the s2Member plugin from child sites?

PostPosted: August 10th, 2011, 7:08 pm
by Cristián Lávaque
Thanks for the great explanations, they really helped me understand this. :)

Re: How do I hide the s2Member plugin from child sites?

PostPosted: August 11th, 2011, 8:39 am
by banta
Cristián, Jason,

Thank you both so much. I'm relatively new to the multisite side of Wordpress - you have actually answered two of my questions there!

Regards,
Denis

Re: How do I hide the s2Member plugin from child sites?

PostPosted: August 11th, 2011, 1:23 pm
by Cristián Lávaque
:)

Re: How do I hide the s2Member plugin from child sites?

PostPosted: October 11th, 2011, 2:41 pm
by scott74
I read each one of the plugins mentioned above but did not see how restricting plugins by role...

For instance you have a gold and silver package...

You want gold members to automatically have plugin 1 and 2 activated when they buy a membership and you want Silver members to have plugin 1,2,3, and 4 avtivated when they join at silver level

You also want to be able to have that plugins 3 and 4 showing to the gold member but it will tell him to upgrade to the silver membership to do so...

I know WPMU.dev has a plugin called supporter that you can upsell themes and plugins that way but its kinda of a high monthly membership... also when you upgrade they have to pay through paypal... would be cool to upsell with pay pal pro..

If anyone can explain the exact plugins to do this or just one that comes close .. feel free.. sorry if i missed something but did not see one above that would restrict by role..... and if they upgrade would the other plugins automatically appear...

should be a plugin that would do that for themes and plugins so the upper membership would include more themes and plugins.. leaving less admin work once set up

Re: How do I hide the s2Member plugin from child sites?

PostPosted: October 12th, 2011, 4:28 pm
by Jason Caldwell
Just a quick reference here, pointing to this thread, where I exposed one of s2Member's Filters, which make it easy to show/hide s2Member menu items based on Role/Capability, or any other criteria you need. See: viewtopic.php?f=4&t=14650&p=32807&hilit=create_users#p33100
Code: Select all
add_filter ("ws_plugin__s2member_during_add_admin_options_create_menu_items", "__return_false"); 

Re: How do I hide the s2Member plugin from child sites?

PostPosted: October 12th, 2011, 5:30 pm
by scott74
hmm.... I'm not so concerned with hiding s2member menu as I dont have it activated network wide... new user who sign up for blogs do not need access to s2 member so I only have it enabled on the main blog which I control...

I was just more concerned with hiding certain plugins form lke a lever 1 member that level 2 member would only see .. same for themes... I guess that is possible somehow with a few hacks