WP_List_Table::get_pagination_arg
Access the pagination args.
Method of the class: WP_List_Table{}
No Hooks.
Returns
Int. Number of items that correspond to the given pagination argument.
Usage
$WP_List_Table = new WP_List_Table(); $WP_List_Table->get_pagination_arg( $key );
- $key(string) (required)
- Pagination argument to retrieve. Common values include
'total_items','total_pages','per_page', or'infinite_scroll'.
Changelog
| Since 3.1.0 | Introduced. |
WP_List_Table::get_pagination_arg() WP List Table::get pagination arg code WP 7.0
public function get_pagination_arg( $key ) {
if ( 'page' === $key ) {
return $this->get_pagenum();
}
return $this->_pagination_args[ $key ] ?? 0;
}