bp_get_document_pagination_count()
Return the document pagination count.
Description
Return
(string) The pagination text.
Source
File: bp-document/bp-document-template.php
function bp_get_document_pagination_count() { global $document_template; $start_num = intval( ( $document_template->pag_page - 1 ) * $document_template->pag_num ) + 1; $from_num = bp_core_number_format( $start_num ); $to_num = bp_core_number_format( ( $start_num + ( $document_template->pag_num - 1 ) > $document_template->total_document_count ) ? $document_template->total_document_count : $start_num + ( $document_template->pag_num - 1 ) ); $total = bp_core_number_format( $document_template->total_document_count ); $message = sprintf( _n( 'Viewing 1 item', 'Viewing %1$s - %2$s of %3$s items', $document_template->total_document_count, 'buddyboss' ), $from_num, $to_num, $total ); return $message; }
Changelog
Version | Description |
---|---|
BuddyBoss 1.4.0 | Introduced. |
Questions?
We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.