BP_Buttons_Group::get( bool $sort = true )
Get the BuddyPress buttons for the group
Description Description
Parameters Parameters
- $sort
-
(Optional) whether to sort the buttons or not.
Default value: true
Return Return
(array) An array of HTML links.
Source Source
File: bp-templates/bp-nouveau/includes/classes.php
public function get( $sort = true ) { $buttons = array(); if ( empty( $this->group ) ) { return $buttons; } if ( true === $sort ) { $this->group = $this->sort( $this->group ); } foreach ( $this->group as $key_button => $button ) { // Reindex with ids. if ( true === $sort ) { $this->group[ $button['id'] ] = $button; unset( $this->group[ $key_button ] ); } $buttons[ $button['id'] ] = bp_get_button( $button ); } return $buttons; }
Changelog Changelog
Version | Description |
---|---|
3.0.0 | Introduced. |