Make WordPress Core


Ignore:
Timestamp:
05/02/2010 10:57:44 PM (16 years ago)
Author:
nacin
Message:

Support network-wide plugin re-activation in upgrades and edits. props PeteMall, fixes #13216

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/class-wp-upgrader.php

    r14173 r14348  
    987987    var $plugin = '';
    988988    var $plugin_active = false;
     989    var $plugin_network_active = false;
    989990
    990991    function Plugin_Upgrader_Skin($args = array()) {
     
    998999        $this->plugin = $args['plugin'];
    9991000
    1000         $this->plugin_active = is_plugin_active($this->plugin);
     1001        $this->plugin_active = is_plugin_active( $this->plugin );
     1002        $this->plugin_network_active = is_plugin_active_for_network( $this->plugin );
    10011003
    10021004        parent::__construct($args);
     
    10071009        if ( !empty($this->plugin) && !is_wp_error($this->result) && $this->plugin_active ){
    10081010            show_message(__('Reactivating the plugin…'));
    1009             echo '<iframe style="border:0;overflow:hidden" width="100%" height="170px" src="' . wp_nonce_url('update.php?action=activate-plugin&plugin=' . $this->plugin, 'activate-plugin_' . $this->plugin) .'"></iframe>';
     1011            echo '<iframe style="border:0;overflow:hidden" width="100%" height="170px" src="' . wp_nonce_url('update.php?action=activate-plugin&networkwide=' . $this->plugin_network_active . '&plugin=' . $this->plugin, 'activate-plugin_' . $this->plugin) .'"></iframe>';
    10101012        }
    10111013
Note: See TracChangeset for help on using the changeset viewer.