Display groups in member search
Last year I’ve written a member management plugin for a client which is working great, there is one thing that’s bugging us though:
By default a few things are displayed on the overview pages:
- Values of some xprofile fields
- Groups the user is a member of
Searching the profiles works great too, but here’s the thing that’s bugging us: the groups aren’t displayed anymore.
I can’t, for the life of me, figure out why it’s doing this. I’ve set the if statement for the groups-loop to this:
if ( bp_has_groups( 'user_id=' . bp_get_member_user_id() . '&type=alphabetical&s=&search_terms=&search_term=&max=100' ) )but it doesn’t work (notice the empty s, search_terms and search_term).
I couldn’t find any search-related options for the bp_has_groups function, but it is going wrong there (since they’re displaying fine when you’re just browsing the profiles).
I also know the
bp_get_member_user_id()is working perfectly inside the user-loop, so that shouldn’t be the issue either.
You must be logged in to reply to this topic.