Using CKFinder 2.4 for PHP. Given the following file list
1.jpg 2.jpg 10.jpg 20.jpg
CKFinder displays files in the following order
1.jpg
10.jpg
2.jpg
20.jpg
whereas using PHP's natcasesort() on the file list array returns files in the following order
1.jpg
2.jpg
10.jpg
20.jpg
I see that natcasesort() is used in GetFiles.php to sort file listings, but the results are not being returned that way -- should I be looking somewhere else?
Yes you are right
Yes you are right PHP connector uses natcasesort() for files and folders. It works with folders but for some reason it doesn't with files.
Files list is sorted correctly on server-side and looking at the XML passed to browser it seems to be still sorted in accordance with natural sort order. I'm not sure but my guess is that something weird is happening on client side thus you see such result.
I have reported this issue on our internal tracker and we will be checking this issue.
OK thank you for checking
OK thank you for checking this out!