Make WordPress Core


Ignore:
Timestamp:
02/14/2010 02:46:38 PM (14 years ago)
Author:
nacin
Message:

Add "Network Activate" option to Bulk Actions menu on plugins.php. See #11644, #12139

File:
1 edited

Legend:

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

    r13082 r13155  
    438438 * @param string|array $plugins
    439439 * @param string $redirect Redirect to page after successful activation.
     440 * @param bool $network_wide Whether to enable the plugin for all sites in the network.
    440441 * @return bool|WP_Error True when finished or WP_Error if there were errors during a plugin activation.
    441442 */
    442 function activate_plugins($plugins, $redirect = '') {
     443function activate_plugins($plugins, $redirect = '', $network_wide) {
    443444    if ( !is_array($plugins) )
    444445        $plugins = array($plugins);
     
    448449        if ( !empty($redirect) )
    449450            $redirect = add_query_arg('plugin', $plugin, $redirect);
    450         $result = activate_plugin($plugin, $redirect);
     451        $result = activate_plugin($plugin, $redirect, $network_wide);
    451452        if ( is_wp_error($result) )
    452453            $errors[$plugin] = $result;
Note: See TracChangeset for help on using the changeset viewer.