WP_List_Table::get_pagenum() – Get the current page number

You appear to be a bot. Output may be restricted

Description

Gets the current page number.

Usage

$int = WP_List_Table::get_pagenum();

Parameters

Returns

int

Source

File name: wordpress/wp-admin/includes/class-wp-list-table.php
Lines:

1 to 9 of 9
  public function get_pagenum() {
    $pagenum = isset( $_REQUEST['paged'] ) ? absint( $_REQUEST['paged'] ) : 0;

    if ( isset( $this->_pagination_args['total_pages'] ) && $pagenum > $this->_pagination_args['total_pages'] ) {
      $pagenum = $this->_pagination_args['total_pages'];
    }

    return max( 1, $pagenum );
  }
 

 View on GitHub View on Trac