Buddypress get member meta info for specific user ID

I am trying to create a ‘featured member’ widget for a Buddypress site, and am using cimy extra fields to add the ‘is featured user’ checkbox. I have some extra user meta fields that were created within the buddypress profile system, like ‘where are you from’ which I want to show on the widget. I am able to query the members/users to get the featured user’s ID, so could someone instruct on how to use bp_has_members() with a specific user ID to get basic member info like: (gravatar) (member name), from (where member is from), is our featured member this month. (profile page link)

Thanks!

Related posts

Leave a Reply

1 comment

  1. to get the buddypress profile field data use:

    bp_get_profile_field_data( array( 
        'field'   => 'your-field-slug',
        'user_id' => $user_id
    ) );
    

    to get the avatar look up bp_get_member_avatar(), and for the name there is bp_displayed_user_fullname() but you need to be in the bp_has_members loop for that one.