diff --git src/wp-admin/includes/class-wp-plugins-list-table.php src/wp-admin/includes/class-wp-plugins-list-table.php
index 3a51d17..1d15e51 100644
|
|
class WP_Plugins_List_Table extends WP_List_Table { |
493 | 493 | list( $plugin_file, $plugin_data ) = $item; |
494 | 494 | $context = $status; |
495 | 495 | $screen = $this->screen; |
| 496 | $is_checked = isset( $_GET['checked'] ) && in_array( $plugin_file, $_GET['checked'] ) ? true : false; |
496 | 497 | |
497 | 498 | // Pre-order. |
498 | 499 | $actions = array( |
… |
… |
class WP_Plugins_List_Table extends WP_List_Table { |
665 | 666 | if ( $restrict_network_active || $restrict_network_only || in_array( $status, array( 'mustuse', 'dropins' ) ) ) { |
666 | 667 | $checkbox = ''; |
667 | 668 | } else { |
668 | | $checkbox = "<label class='screen-reader-text' for='" . $checkbox_id . "' >" . sprintf( __( 'Select %s' ), $plugin_data['Name'] ) . "</label>" |
669 | | . "<input type='checkbox' name='checked[]' value='" . esc_attr( $plugin_file ) . "' id='" . $checkbox_id . "' />"; |
| 669 | $checkbox = sprintf( |
| 670 | '<label class="screen-reader-text" for="%s">%s</label>', |
| 671 | $checkbox_id, |
| 672 | sprintf( __( 'Select %s' ), $plugin_data['Name'] ) |
| 673 | ); |
| 674 | $checkbox .= sprintf( |
| 675 | '<input type="checkbox" name="checked[]" value="%s" id="%s" %s />', |
| 676 | esc_attr( $plugin_file ), |
| 677 | $checkbox_id, |
| 678 | checked( $is_checked, true, false ) |
| 679 | ); |
670 | 680 | } |
671 | 681 | if ( 'dropins' != $context ) { |
672 | 682 | $description = '<p>' . ( $plugin_data['Description'] ? $plugin_data['Description'] : ' ' ) . '</p>'; |
diff --git src/wp-admin/plugins.php src/wp-admin/plugins.php
index 93aec79..bf9babf 100644
|
|
if ( $action ) { |
114 | 114 | update_site_option( 'recently_activated', $recent ); |
115 | 115 | } |
116 | 116 | |
117 | | wp_redirect( self_admin_url("plugins.php?activate-multi=true&plugin_status=$status&paged=$page&s=$s") ); |
| 117 | $post_activation_query_args = array( |
| 118 | 'activate-multi' => 'true', |
| 119 | 'plugin_status' => $status, |
| 120 | 'paged' => $page, |
| 121 | 's' => $s, |
| 122 | 'checked' => array(), |
| 123 | ); |
| 124 | |
| 125 | foreach ( $plugins as $checked_plugin ) { |
| 126 | $post_activation_query_args['checked'][] = $checked_plugin; |
| 127 | } |
| 128 | |
| 129 | wp_redirect( esc_url_raw( add_query_arg( $post_activation_query_args, self_admin_url( 'plugins.php' ) ) ) ); |
118 | 130 | exit; |
119 | 131 | |
120 | 132 | case 'update-selected' : |
… |
… |
if ( $action ) { |
223 | 235 | update_site_option( 'recently_activated', $deactivated + (array) get_site_option( 'recently_activated' ) ); |
224 | 236 | } |
225 | 237 | |
226 | | wp_redirect( self_admin_url("plugins.php?deactivate-multi=true&plugin_status=$status&paged=$page&s=$s") ); |
| 238 | $post_deactivation_query_args = array( |
| 239 | 'deactivate-multi' => 'true', |
| 240 | 'plugin_status' => $status, |
| 241 | 'paged' => $page, |
| 242 | 's' => $s, |
| 243 | 'checked' => array(), |
| 244 | ); |
| 245 | |
| 246 | foreach ( $plugins as $checked_plugin ) { |
| 247 | $post_deactivation_query_args['checked'][] = $checked_plugin; |
| 248 | } |
| 249 | |
| 250 | wp_redirect( esc_url_raw( add_query_arg( $post_deactivation_query_args, self_admin_url( 'plugins.php' ) ) ) ); |
227 | 251 | exit; |
228 | 252 | |
229 | 253 | case 'delete-selected': |