On Wed, 16 Feb 2005 09:23:03 -0800, Jan Steinman Jan@bytesmiths.com wrote:
is there something like a <sort>-Tag in Mediawiki?
Sounds like a job for an extension. Sounds like a couple hours of work max if you know your way around PHP and Unix.
Still seems like something best done externally and then dumped back in the wiki by humans to me - especially since that way it would be permanent, rather than being recalculated every time the page was viewed. And if the source is unsorted, you've got the increased risk of people adding duplicates because they'll dump everything at the end rather than finding the right place to add it; then the list will sort itself, and the duplicates will end up next to each other - but when someone goes to edit the list, they'll have to hunt through to find where they are in the source...
To make the sorting really easy, if you think it's going to happen a lot, you could put a form up on your website that lets people sort stuff. For a quick hack in pure PHP, copy http://195.137.84.82/~ron/sort.php.txt - you'll want to tidy it up, especially in terms of prettifying the HTML, but in general that's all you need.
Note that the function I used there, "natcasesort", is not only case insensitive, but is designed to act "like a human would", so for instance:
* [[link4]] * [[link10]] *[[Link2]] * [[LINK3]] * [[link 1]]
becomes:
* [[link 1]] *[[Link2]] * [[LINK3]] * [[link4]] * [[link10]]