Skip to:
Content
Pages
Categories
Search
Top
Bottom

Is this a bug?

  • Avatar of nyodulf
    nyodulf
    Participant

    @nyodulf

    I’m using separate first name and last name xprofile fields (wish I hadn’t as BP doesn’t deal with this well at all, but it’s too late). However, in order to get full names showing up I’ve been trying to use ‘bp_get_member_profile_data’. It wasn’t working, so I did some digging and in ‘bp-members-template.php’ there is the following code (line 604):
    `if ( !empty( $members_template->member->id ) )
    $user_id = $members_template->member->id;`
    But when I print the $members_template global, there is no key ‘id’, it’s called ‘user_id’. If I change that core file to use ‘user_id’, my full name solution works as expected.

    Is that a bug, or am I missing something?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Avatar of shanebp
    shanebp
    Moderator

    @shanebp

    Where are you trying to get the Full Names to show up ?

    I think $members_template is for use inside the members loop.

    Have you looked at the plugins/buddypress/bp-xprofile code ?

    > However, in order to get full names showing up I’ve been trying to use ‘bp_get_member_profile_data’. It wasn’t working,

    Post the snippet of your attempt and tell us where you called it. And your BP version.

    Can you debug the SQL queries in BP_Core_User::get_users() and let me know (via pastebin.com, or somewhere) what the query is?

    It *looks* as though ID should be getting set, so I’m interested in what the database query’s actually asking for.

Viewing 2 replies - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.