WP_Posts_List_Table::is_base_request() WordPress Method
The WP_Posts_List_Table::is_base_request() method is used to determine whether the current request is for the posts list table.
WP_Posts_List_Table::is_base_request() #
Determine if the current view is the “All” view.
Return
(bool) Whether the current view is the "All" view.
Source
File: wp-admin/includes/class-wp-posts-list-table.php
protected function is_base_request() {
$vars = $_GET;
unset( $vars['paged'] );
if ( empty( $vars ) ) {
return true;
} elseif ( 1 === count( $vars ) && ! empty( $vars['post_type'] ) ) {
return $this->screen->post_type === $vars['post_type'];
}
return 1 === count( $vars ) && ! empty( $vars['mode'] );
}
Expand full source codeCollapse full source codeView on TracView on GitHub
Changelog
| Version | Description |
|---|---|
| 4.2.0 | Introduced. |