Getting group name from id
-
Hey,
I’m trying to add a group with it’s last activities to the sidebar of logged in users.
Displaying the activities was easy and works great with bp_has_activities().Now I want to display the name of the group.
I can get the ID’s withBP_Groups_Member::get_group_ids( get_current_user_id());
I select a single ID of that array and try to get the name of the group with:
$group = groups_get_group( array( ‘group_id’ => $id-of-group) );
This returns an array with the right keys, but they don’t have values. It also returns empty values when I replace ‘$id-of-group’ with the number of the group I found in phpMyadmin, so that’s not the problem.Anything I’m missing or any other way to get the group name?
Thanks!WP:3.8.1
BP: 1.8.1
(Website: 24baby.nl)
- The topic ‘Getting group name from id’ is closed to new replies.