Networks and Sites: Add support for the extra_tablenav() method in WP_MS_Sites_List_Table.

This method allows additional filters or other UI components to be added to the top and bottom of the `WP_List_Table` between the bulk actions dropdown and search input field.

Fixes #45954.
Props pbiron, desrosj.

git-svn-id: https://develop.svn.wordpress.org/trunk@46211 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Jonathan Desrosiers
2019-09-20 20:52:58 +00:00
parent 6b65af939f
commit e31bd15ab5
2 changed files with 47 additions and 7 deletions

View File

@@ -231,14 +231,12 @@ if ( isset( $_GET['action'] ) ) {
wp_safe_redirect( $redirect_to );
exit();
}
} else {
$location = network_admin_url( 'sites.php' );
if ( ! empty( $_REQUEST['paged'] ) ) {
$location = add_query_arg( 'paged', (int) $_REQUEST['paged'], $location );
}
wp_redirect( $location );
exit();
} elseif ( ! empty( $_GET['_wp_http_referer'] ) ) {
// process query defined by WP_MS_Site_List_Table::extra_table_nav().
wp_redirect( remove_query_arg( array( '_wp_http_referer', '_wpnonce' ), wp_unslash( $_SERVER['REQUEST_URI'] ) ) );
exit;
}
break;
case 'archiveblog':