BP_Activity_List_Table::get_views()
Get the list of views available on this table (e.g. “all”, “spam”).
Description
Source
File: bp-activity/classes/class-bp-activity-list-table.php
330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 | function get_views() { $url_base = add_query_arg( array ( 'page' => 'bp-activity' ), bp_get_admin_url( 'admin.php' ) ); ?> <h2 class = "screen-reader-text" ><?php /* translators: accessibility text */ _e( 'Filter activities list' , 'buddyboss' ); ?></h2> <ul class = "subsubsub" > <li class = "all" ><a href= "<?php echo esc_url( $url_base ); ?>" class = "<?php if ( 'spam' != $this->view ) echo 'current'; ?>" ><?php _e( 'All' , 'buddyboss' ); ?></a> |</li> <li class = "spam" ><a href= "<?php echo esc_url( add_query_arg( array( 'activity_status' => 'spam' ), $url_base ) ); ?>" class = "<?php if ( 'spam' == $this->view ) echo 'current'; ?>" ><?php printf( __( 'Spam <span class="count">(%s)</span>' , 'buddyboss' ), number_format_i18n( $this ->spam_count ) ); ?></a></li> <?php /** * Fires inside listing of views so plugins can add their own. * * @since BuddyPress 1.6.0 * * @param string $url_base Current URL base for view. * @param string $view Current view being displayed. */ do_action( 'bp_activity_list_table_get_views' , $url_base , $this ->view ); ?> </ul> <?php } |
Changelog
Version | Description |
---|---|
BuddyPress 1.6.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.