diff options
Diffstat (limited to 'wp-admin/includes/class-wp-list-table.php')
-rw-r--r-- | wp-admin/includes/class-wp-list-table.php | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/wp-admin/includes/class-wp-list-table.php b/wp-admin/includes/class-wp-list-table.php index 4e6aaa4..2879a0a 100644 --- a/wp-admin/includes/class-wp-list-table.php +++ b/wp-admin/includes/class-wp-list-table.php @@ -388,7 +388,13 @@ class WP_List_Table { $input_id = $input_id . '-search-input'; if ( ! empty( $_REQUEST['orderby'] ) ) { - echo '<input type="hidden" name="orderby" value="' . esc_attr( $_REQUEST['orderby'] ) . '" />'; + if ( is_array( $_REQUEST['orderby'] ) ) { + foreach ( $_REQUEST['orderby'] as $key => $value ) { + echo '<input type="hidden" name="orderby[' . esc_attr( $key ) . ']" value="' . esc_attr( $value ) . '" />'; + } + } else { + echo '<input type="hidden" name="orderby" value="' . esc_attr( $_REQUEST['orderby'] ) . '" />'; + } } if ( ! empty( $_REQUEST['order'] ) ) { echo '<input type="hidden" name="order" value="' . esc_attr( $_REQUEST['order'] ) . '" />'; @@ -635,7 +641,7 @@ class WP_List_Table { return false; } - if ( isset( $_REQUEST['action'] ) && -1 != $_REQUEST['action'] ) { + if ( isset( $_REQUEST['action'] ) && '-1' !== $_REQUEST['action'] ) { return $_REQUEST['action']; } @@ -753,7 +759,7 @@ class WP_List_Table { $month_count = count( $months ); - if ( ! $month_count || ( 1 == $month_count && 0 == $months[0]->month ) ) { + if ( ! $month_count || ( 1 === $month_count && 0 === (int) $months[0]->month ) ) { return; } @@ -764,7 +770,7 @@ class WP_List_Table { <option<?php selected( $m, 0 ); ?> value="0"><?php _e( 'All dates' ); ?></option> <?php foreach ( $months as $arc_row ) { - if ( 0 == $arc_row->year ) { + if ( 0 === (int) $arc_row->year ) { continue; } @@ -989,10 +995,10 @@ class WP_List_Table { * - `edit_comments_per_page` * - `sites_network_per_page` * - `site_themes_network_per_page` - * - `themes_network_per_page'` + * - `themes_network_per_page` * - `users_network_per_page` * - `edit_post_per_page` - * - `edit_page_per_page'` + * - `edit_page_per_page` * - `edit_{$post_type}_per_page` * - `edit_post_tag_per_page` * - `edit_category_per_page` @@ -1053,11 +1059,11 @@ class WP_List_Table { $disable_prev = false; $disable_next = false; - if ( 1 == $current ) { + if ( 1 === $current ) { $disable_first = true; $disable_prev = true; } - if ( $total_pages == $current ) { + if ( $total_pages === $current ) { $disable_last = true; $disable_next = true; } |