Skip to:

Opened 13 years ago

Closed 13 years ago

#3162 closed defect (bug) (fixed)

Alphabetical list doesn't sort properly if user enters spaces

Reported by: defunctlife's profile defunctlife Owned by:
Milestone: 1.5 Priority: normal
Severity: Version:
Component: Extended Profile Keywords:


Ran into an issue where if a user had a leading space in their name, they would be placed at the top of the memberlist when sorting by alphabetical.

Attachments (1)

3162-1.patch (1.2 KB) - added by DJPaul 13 years ago.

Download all attachments as: .zip

Change History (4)

#1 @defunctlife
13 years ago

Sorry, I didn't have time to create a diff.

But I changed:

$sql[] = "ORDER BY pd.value ASC";


$sql[] = "ORDER BY ltrim(pd.value) ASC";

line 179, bp 1.2.8. bp-core/bp-core-classes.php

#2 @DJPaul
13 years ago

  • Component changed from Core to XProfile
  • Milestone changed from Awaiting Review to 1.3

Better to trim when we save the data

13 years ago

#3 @djpaul
13 years ago

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

(In [4221]) Trim profile data on save to avoid trailing spaces. Fixes #3162

Note: See TracTickets for help on using tickets.