Skip to:

Opened 5 years ago

Closed 5 years ago

Last modified 4 years ago

#4937 closed defect (bug) (fixed)

Popular Members Widget - Doesn't show all members

Reported by: allenpayne Owned by: boonebgorges
Milestone: 1.8 Priority: normal
Severity: normal Version: 1.7
Component: Core Keywords:
Cc: sam3dus@…, mert@…



I just updated to wp 3.5.1 and buddypress 1.7 and i have an unusual problem with the Members widget.

I currently have 3k+ members on my site and my top member has 400+ friends.

When i add the Members widget to the sidebar and click on Popular…it shows a list of member starting with the member with 96 friends.

For some reason it doesn’t show the top members (starting with the one with 400+ friends).

Any ideas?

I tried to replace the bp-core-widgets.php file with the one from the previous version, but it didn’t work.

Attachments (1)

4937.diff (609 bytes) - added by merty 5 years ago.

Download all attachments as: .zip

Change History (19)

#1 @boonebgorges
5 years ago

  • Keywords reporter-feedback added

Hm. Please try putting the following into your bp-custom.php file, and see what happens:

add_filter( 'bp_use_legacy_user_query', '__return_true' );

If that fixes it, it'll suggest that there's a bug in BP_User_Query.

#2 @allenpayne
5 years ago

Thanks for getting back to me Boone.

This fixed the problem.

Is this a good solution? Can i leave it like that?

#3 @boonebgorges
5 years ago

  • Keywords reporter-feedback removed
  • Milestone changed from Awaiting Review to 1.8
  • Severity changed from major to normal

Yes, you can leave it like that, until this ticket has been marked as fixed and the fix has gone into a release version.

#4 @allenpayne
5 years ago

Ok, Boone. Thanks for your help. I really appreciate it.

#5 follow-up: @boonebgorges
5 years ago

Thanks for reporting the issue! I may ask you to test any potential fixes.

#6 @shanebp
5 years ago

  • Cc sam3dus@… added

#7 in reply to: ↑ 5 @allenpayne
5 years ago

Replying to boonebgorges:

Thanks for reporting the issue! I may ask you to test any potential fixes.

Sure, Boone. Just let me know...

5 years ago

#8 @merty
5 years ago

  • Keywords has-patch needs-testing added

This should fix it.

#9 @AllenPayne
5 years ago

Your patch works. Thank you @merty.

Last edited 5 years ago by AllenPayne (previous) (diff)

#10 @merty
5 years ago

  • Keywords needs-testing removed

You're welcome! Thanks for testing it!

#11 @merty
5 years ago

  • Cc mert@… added

#12 @boonebgorges
5 years ago

Patch looks great, thanks merty!

#13 @boonebgorges
5 years ago

  • Owner set to boonebgorges
  • Resolution set to fixed
  • Status changed from new to closed

In 6996:

Convert total_friend_count to SIGNED before attempting to sort with it

This fixes issues in BP_User_Query where the 'popular' sort order was sorting
by friend count interpreted as a string (ie, alphabetically) instead of

Fixes #4937

Props merty

#14 @CarlosRovira
4 years ago

  • Keywords has-patch removed

Hi I'm using latest version 1.9.2, and this bugs seems still there. I tried the fix exposed with no luck.

Is a new ticket for this problem? (if so, some could point me to it?)

If there's no ticket I will create a new one.

Thanks in advance

#15 @boonebgorges
4 years ago

  • Keywords reporter-feedback added

CarlosRovira - Can you please give further details?

#16 @CarlosRovira
4 years ago

Thanks Boone for your quickly response:

The site where you can see the problem is:

In the home near the final you can see "USUARIOS EN LA COMUNIDAD DE MADE IN FLEX"

This is the Member User BuddyPress Widget.

I have 36 people configured. I expect to see 32 people (people already in the community). And get up to 36 when have enough people to show.

But right now only shows 20. If I click "Activo" label it shows 32 people (is what is expected). And if I come back to "Nuevos", it show 32.

So the problem seems to be on the load of the plugin.

I don't use any custom code, just plugins, and this widget seems to be BP core widget, isn't it?

I'll try the links you comment to see If I can fix it

#17 @boonebgorges
4 years ago

  • Keywords reporter-feedback removed

Thanks for the additional details, CarlosRovira. This appears to be a separate problem, related to the 'max' or 'per_page' parameter. Could you please open a separate ticket, describing what you describe above? And be sure to share the exact settings you set up when you created the widget at Dashboard > Appearance > Widgets. Thanks!

#18 @CarlosRovira
4 years ago

HI Boone,

ticket created as you requested



Note: See TracTickets for help on using tickets.