This is a static dump of issues in the old "Flyspray" bugtracker for DokuWiki. Bugs and feature requests
are now tracked at the issue tracker at Github.
Closed
Implemented
FS#2245 Natural sorting in sitemap
Customization
2011-05-05molefunk
Is there any possibility of rendering the index with natural sorting?
I'm storing thousands of pages in numerical format, but I have to keep them "clean", ie. without zeroes in front not to mess up my links.
This would be very helpful, at least for me.
2011-05-21molefunk
Okay, revisiting this I see the need for using more appropriate title and better description.
So, title could instead read eg. "Natural sorting in sitemap." Feel free to edit anyone with permission!
Cheers! :)
2011-05-22ach
Done.
BTW, do you think it's better to always show the sitemap with natural sorting or to introduce a config option? Does anyone need anything *but* natural sorting?
2011-05-22molefunk
It could be introduced as an option, by all means, but I do not see any need for sorting otherwise, and those who'd notice would most likely be happy about it.
2013-01-27ChrisS
I've looked into this. The sorting happens in search() within inc/search.php on lines 45 & 47. Changing to use natsort() rather than sort() looks to be equally beneficial to other users of the function (mediamanager & xmlrpc).
I also note that a '$sort' parameter was added to search() for the new media manager (https://github.com/splitbrain/dokuwiki/commit/abc306f45f2ace038967bf7c51abd6ea53f56170). Currently there are two possible values, false and 'date'. A less invasive way of making this change would be to add 'natural' as an option. Regardless, documenting the sort parameter should be part of this FS.