Getting group name from id
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 with
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?
You must be logged in to reply to this topic.