php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #43145 Add support for SORT_LOCALE_STRING to array_multisort() function
Submitted: 2007-10-30 16:07 UTC Modified: 2011-07-27 13:34 UTC
Votes:40
Avg. Score:4.5 ± 0.7
Reproduced:34 of 34 (100.0%)
Same Version:20 (58.8%)
Same OS:24 (70.6%)
From: sw at veracomp dot pl Assigned: arpad (profile)
Status: Closed Package: *General Issues
PHP Version: 5.2.4 OS: Linux / Any
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: sw at veracomp dot pl
New email:
PHP Version: OS:

 

 [2007-10-30 16:07 UTC] sw at veracomp dot pl
Description:
------------
Hi,

I'm writing an application that utilizes the array_multisort function.
We have to sort data in polish language whitch contains non-ASCII characters.

We tried to pass SORT_LOCALE_STRING to the function, but the but it produces warning:

  Argument #3 is an unknown sort flag

We are aware that the Docs says it supports only SORT_STRING, SORT_REGULAR and SORT_NUMERIC flags, but we do need locale sorting.

Please add support for SORT_LOCALE_STRING flag to this function.


Thanks, in advance
Szymon Wilkolazki


Reproduce code:
---------------
array_multisort($columnsArray, SORT_ASC, SORT_LOCALE_STRING, $theDataToBeSorted );

Expected result:
----------------
Table sorted.

Actual result:
--------------
Warning: array_multisort() [function.array-multisort]: Argument #3 is an unknown sort flag in...

Table not sorted.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2011-07-27 13:34 UTC] arpad@php.net
-Status: Open +Status: Closed -Package: Feature/Change Request +Package: *General Issues -Assigned To: +Assigned To: arpad
 [2011-07-27 13:34 UTC] arpad@php.net
This is implemented in PHP 5.3+ on platforms where strcoll is available.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Fri Mar 14 17:01:29 2025 UTC