| [ Index ] |
PHP Cross Reference of WordPress Trunk (Updated Daily) |
[Source view] [Print] [Project Stats]
List Table API: WP_Posts_List_Table class
| File Size: | 2252 lines (68 kb) |
| Included or required: | 0 times |
| Referenced: | 0 times |
| Includes or requires: | 0 files |
WP_Posts_List_Table:: (34 methods):
__construct()
set_hierarchical_display()
ajax_user_can()
prepare_items()
has_items()
no_items()
is_base_request()
get_edit_link()
get_views()
get_bulk_actions()
categories_dropdown()
formats_dropdown()
extra_tablenav()
current_action()
get_table_classes()
get_columns()
get_sortable_columns()
display_rows()
_display_rows()
_display_rows_hierarchical()
_page_rows()
get_no_title_excerpt()
column_cb()
_column_title()
get_primary_column_aria_label()
column_title()
column_date()
column_comments()
column_author()
column_default()
single_row()
get_default_primary_column_name()
handle_row_actions()
inline_edit()
Class: WP_Posts_List_Table - X-Ref
Core class used to implement displaying posts in a list table.| __construct( $args = array() X-Ref |
| Constructor. param: array $args An associative array of arguments. |
| set_hierarchical_display( $display ) X-Ref |
| Sets whether the table layout should be hierarchical or not. param: bool $display Whether the table layout should be hierarchical. |
| ajax_user_can() X-Ref |
return: bool |
| prepare_items() X-Ref |
| has_items() X-Ref |
return: bool |
| no_items() X-Ref |
| No description |
| is_base_request() X-Ref |
| Determines if the current view is the "All" view. return: bool Whether the current view is the "All" view. |
| get_edit_link( $args, $link_text, $css_class = '' ) X-Ref |
| Creates a link to edit.php with params. param: string[] $args Associative array of URL parameters for the link. param: string $link_text Link text. param: string $css_class Optional. Class attribute. Default empty string. return: string The formatted link string. |
| get_views() X-Ref |
return: array |
| get_bulk_actions() X-Ref |
return: array |
| categories_dropdown( $post_type ) X-Ref |
| Displays a categories drop-down for filtering on the Posts list table. param: string $post_type Post type slug. |
| formats_dropdown( $post_type ) X-Ref |
| Displays a formats drop-down for filtering items. param: string $post_type Post type slug. |
| extra_tablenav( $which ) X-Ref |
param: string $which |
| current_action() X-Ref |
return: string |
| get_table_classes() X-Ref |
return: array |
| get_columns() X-Ref |
return: string[] Array of column titles keyed by their column name. |
| get_sortable_columns() X-Ref |
return: array |
| display_rows( $posts = array() X-Ref |
| Generates the list table rows. param: array $posts param: int $level |
| _display_rows( $posts, $level = 0 ) X-Ref |
param: array $posts param: int $level |
| _display_rows_hierarchical( $pages, $pagenum = 1, $per_page = 20 ) X-Ref |
param: array $pages param: int $pagenum param: int $per_page |
| _page_rows( &$children_pages, &$count, $parent_page, $level, $pagenum, $per_page, &$to_display ) X-Ref |
| Displays the nested hierarchy of sub-pages together with paging support, based on a top level page ID. param: array $children_pages param: int $count param: int $parent_page param: int $level param: int $pagenum param: int $per_page param: array $to_display List of pages to be displayed. Passed by reference. |
| get_no_title_excerpt( $post ) X-Ref |
| Gets a trimmed excerpt to display in place of a missing post title. Only returns text in the Compact list view for posts that have no title, do not require a password, and that the current user is allowed to read. param: WP_Post $post The current WP_Post object. return: string The escaped, trimmed excerpt, or an empty string. |
| column_cb( $item ) X-Ref |
| Handles the checkbox column output. param: WP_Post $item The current WP_Post object. |
| _column_title( $post, $classes, $data, $primary ) X-Ref |
param: WP_Post $post param: string $classes param: string $data param: string $primary |
| get_primary_column_aria_label( $item ) X-Ref |
| Returns a clean label for the primary (title) column's row header `aria-label`. Provides screen readers with just the post title as the row header name, preventing them from computing the name from the full cell content (which includes row action links, post states, and possibly an excerpt). param: WP_Post $item The current post object. return: string The post title, or 'no title' if no title. |
| column_title( $post ) X-Ref |
| Handles the title column output. param: WP_Post $post The current WP_Post object. |
| column_date( $post ) X-Ref |
| Handles the post date column output. param: WP_Post $post The current WP_Post object. |
| column_comments( $post ) X-Ref |
| Handles the comments column output. param: WP_Post $post The current WP_Post object. |
| column_author( $post ) X-Ref |
| Handles the post author column output. param: WP_Post $post The current WP_Post object. |
| column_default( $item, $column_name ) X-Ref |
| Handles the default column output. param: WP_Post $item The current WP_Post object. param: string $column_name The current column name. |
| single_row( $post, $level = 0 ) X-Ref |
param: int|WP_Post $post param: int $level |
| get_default_primary_column_name() X-Ref |
| Gets the name of the default primary column. return: string Name of the default primary column, in this case, 'title'. |
| handle_row_actions( $item, $column_name, $primary ) X-Ref |
| Generates and displays row action links. param: WP_Post $item Post being acted upon. param: string $column_name Current column name. param: string $primary Primary column name. return: string Row actions output for posts, or an empty string |
| inline_edit() X-Ref |
| Outputs the hidden row displayed when inline editing |
| Generated : Thu Aug 6 08:20:21 2026 | Cross-referenced by PHPXref |