Currently 18:27:20 GMT

(Login | Register)

Owner: Samsonasu

Type: WPMU Plugin

Created: 2006-07-26 00:00:00

Last Modified: 2006-07-26 00:00:00


plugman.php (4383 download(s))

Manage global plugin policies or just turn on and off plugins for individual blogs - without enabing like the plugin backend menu.



Posted 2006-07-30 15:10:32 by mrjcleaver.

http://mu.wordpress.org/forums/topic.php?id=1598&replies=3


Posted 2006-07-30 15:11:13 by mrjcleaver.

it'd be useful if links to known good places (e.g. wordpress.org) were actually linked.


Posted 2006-08-05 17:31:55 by chrisjdavis.

I have patched this plugin so that the global deactivate works now. I still want to clean up some of the code a bit, but it does work for now. You can get the modded version at http://www.chrisjdavis.org/downloads/wpmu/plugman-reloaded.zip


Posted 2006-08-05 17:33:08 by chrisjdavis.

That should be download, not downloads. Someone install the editing plugin!


Posted 2006-09-17 04:26:06 by SignpostMarv Martin.

Noink. I fixed some of the HTML stuff (layout, semantics) I added two functions to help give the global manager a 4-column display similar to the blog-specific layout- is_plugin_globally_active() and is_plugin_globally_inactive(). Altered check_plugins() so that it a) wouldn't spill off the side of the page, and b) displays the name. Apologies for restructuring the syntax (it's what I'm used to), but I don't appear to have borked anything :-)


Posted 2006-09-22 02:55:55 by snake.

Hi Martin, accourding to ur plugman-revisited.php, thx for ur effort and I also found out some warnings displayed when I use the revisited version. so I made little addjustment :

  • line287:
    if( 0==count($plugins) || in_array($file,$plugins)) // before fix: if(in_array($file,$plugins))
and also, for pppl who use not the default table prefix, they would have problem of activating plug-ins because some hard-coded sql in function activate_plugin so I also made changes to it in the first 3 lines:
  • function activate_plugin($plugin, $blogid = 'all') { global $wpdb; // new add $query = "select blog_id from {$wpdb->blogs}"; // wp_blogs =>{$wpdb->blogs} if ($blogid != 'all') // 0 => 'all' { $query = $query . " where blog_id = $blogid"; }
Hope this will help


Posted 2006-09-22 02:58:03 by snake.

the part two modification for the last post:

function activate_plugin($plugin, $blogid = 'all') {
global $wpdb; // new add
$query = "select blog_id from {$wpdb->blogs}"; // wp_blogs =>{$wpdb->blogs}
if ($blogid != 'all') // 0 => 'all' {
$query = $query . " where blog_id = $blogid";
}


Posted 2006-10-17 19:48:02 by SignpostMarv Martin.

Your line 287 fix interferes with the efficiency of the action links generation- with your fix it displays both links all the time when it's only supposed to show both links when the plugin isn't globally enabled or disabled (e.g. some blogs have different settings to the rest of them)


Posted 2006-10-25 14:31:51 by bishop.

actually this plugin doesn't support WPMU 1.0 :-(


Posted 2006-12-12 10:26:08 by k0rp0rate.

I was using this fabulous plugin for months without any problem... But after upgrading to the lastest wpmu nightly-build (two days ago), I cant use anymore this plugin No matter what version (original plugman, reloaded, or revisited), all of them gives me the same error. When trying to acces to the Admin wpmu section I get the "Cant load nameofthefile.php" but the file is there and was working for a while after upgrading... Any fix for this??


Posted 2006-12-24 10:03:36 by frptech.

Any luck with this on WPMU 1.0?


Posted 2007-01-30 08:38:40 by johnweb.

Works for me so far, love it.


Posted 2007-04-27 02:39:08 by nunsuch.

Have a weird problem. Plugin Manager works at times, not at the others. Not 100% sure, but it seems that, once I globally activate 1 plugin, I can't do the next one - Display active plugins goes blank (wp-admin/wpmu-admin.php?page=mu-plugins/plugman.php&view=check) and clicking on global activate any plugins (/wp-admin/wpmu-admin.php?page=mu-plugins/plugman.php&action=activate&blog=0&plugin=anarchy_media/anarchy_media_player.php&view=detail) does the same. Once I remove the plugins and reinstall them (they are not active any more), everything works again. This happens no matter what plugin is being activated. wordpress-mu-1.2.1 Plugin Manager Version: 1.0 Hope someone can help... I can't get to the php errors, sorry.


Posted 2007-05-04 10:14:11 by robyinno.

Modified version for Mu 1.2.1
With Mu 1.2.1 some plugin activation doesn't work, with the following modification work for me.

Starting from the plugman-revisited.php, with modification of make by snake
You can apply this patch:
line 383, after $res = mysql_query($query);
@include_once(ABSPATH . PLUGINDIR . '/' . $plugin);
$saved_table_prefix=$table_prefix;
line 408, after update_blog_option($blogid, "active_plugins", $plugins);
// mod ri at ants.eu
$table_prefix="wp_".$blogid."_";
switch_to_blog($blogid);
do_action('activate_' . $plugin);
restore_current_blog();
after echo "Done!"; }
$table_prefix=$saved_table_prefix;
line 425, after update_blog_option($bid->blog_id, "active_plugins", $plugins);
// mod ri at ants.eu
do_action('deactivate_' . $plugin);


Posted 2007-06-29 17:50:51 by mrjcleaver.

Can someone please release a consolidated version of this plugin with modifications for wpmu 1.2.x?


Posted 2007-07-09 00:08:16 by SignpostMarv Martin.

Yar, Consolidated quirkyness the modifications discussed have been integrated into the new source location, I'll be taking down the sitesled source at some point now I have my own "proper" host. I had some errors about unserialization when globally activating a plugin- the interface didn't say it was globally activated on the immediate page load, but subsequent page loads showed it had been activated.


Posted 2007-07-23 06:19:26 by conpeo.

thnx bro, may i know how to fix the warning msg? using wpmu1.2.3 Warning: in_array() [function.in-array]: Wrong datatype for second argument in /blog/wp-content/mu-plugins/plugman.php on line 293


Posted 2007-08-04 08:21:17 by kivan.

I've got same error as conpeo and in addition a fatal error : Fatal error: Allowed memory size of 16777216 bytes exhausted (tried to allocate 291051 bytes) in /home/www/02cf37e5c524c48f57a3cbb9e59d825f/web/wp-includes/cache.php on line 48 I really need plugman, thanks for your help in advance !


Posted 2007-10-29 12:15:06 by mat123.

Anyone else have problems uninstalling plugman? I globally deactivated but it didin't do anything.


You must be registered and logged in to post comments. Not registered? Click here to get your free account!