rtmedia_offset

Get the page offset for the media pool.

Description

(int) rtmedia_offset(); 

Returns (int)


Usage

  1. if ( !function_exists( 'rtmedia_offset' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'rtmedia-for-wordpress-buddypress-and-bbpress/app/main/controllers/template/rtmedia-functions.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = rtmedia_offset(); 
  7.  

Defined (1)

The function is defined in the following location(s).

/app/main/controllers/template/rtmedia-functions.php  
  1. function rtmedia_offset() { 
  2.  
  3. global $rtmedia_query; 
  4.  
  5. return ( $rtmedia_query->action_query->page - 1 ) * $rtmedia_query->action_query->per_page_media; 
  6.