diff --git a/wp-admin/includes/class-wp-upgrader.php b/wp-admin/includes/class-wp-upgrader.php index 048d58cf6..e373d9dd7 100644 --- a/wp-admin/includes/class-wp-upgrader.php +++ b/wp-admin/includes/class-wp-upgrader.php @@ -271,6 +271,7 @@ class WP_Upgrader { 'destination' => '', //And this 'clear_destination' => false, 'clear_working' => true, + 'is_multi' => false, 'hook_extra' => array() //Pass any extra $hook_extra args here, this will be passed to any hooked filters. ); @@ -287,7 +288,9 @@ class WP_Upgrader { return $res; } - $this->skin->header(); + if ( !$is_multi ) // call $this->header separately if running multiple times + $this->skin->header(); + $this->skin->before(); //Download the package (Note, This just returns the filename of the file if the package is a local file) @@ -321,7 +324,10 @@ class WP_Upgrader { $this->skin->feedback('process_success'); } $this->skin->after(); - $this->skin->footer(); + + if ( !$is_multi ) + $this->skin->footer(); + return $result; } @@ -355,6 +361,7 @@ class Plugin_Upgrader extends WP_Upgrader { var $result; var $bulk = true; + var $show_before = ''; function upgrade_strings() { $this->strings['up_to_date'] = __('The plugin is at the latest version.'); @@ -447,7 +454,14 @@ class Plugin_Upgrader extends WP_Upgrader { add_filter('upgrader_pre_install', array(&$this, 'deactivate_plugin_before_upgrade'), 10, 2); add_filter('upgrader_clear_destination', array(&$this, 'delete_old_plugin'), 10, 4); + $this->skin->header(); + $all = count($plugins); + $i = 1; foreach ( $plugins as $plugin ) { + + $this->show_before = sprintf( '