Time to play secretary.... per our conversation in IRC:
I'll paraphase with a CVS diff:
Index: shared-manual.inc
===================================================================
RCS file: /repository/phpweb/include/shared-manual.inc,v
retrieving revision 1.192
diff -u -r1.192 shared-manual.inc
--- shared-manual.inc 2 Jun 2003 09:49:46 -0000 1.192
+++ shared-manual.inc 3 Jun 2003 19:19:27 -0000
@@ -254,6 +254,10 @@
echo 'There are no user contributed notes for this page.';
echo '</td></tr>';
} else {
+ if (strtoupper($_COOKIE['NOTES_ORDER']) == 'ASC') {
+ $notes = array_reverse($notes);
+ }
+
foreach($notes as $note) {
makeEntry($note['xwhen'], $note['user'], $note['note'],
$note['id']);
}
This is of course incomplete as it doesn't include anyway to set the cookie
(and it doesn't bear in mind BC with mirrors running older versions), but
the idea is simple enough. Let the user choose the sort order at a
not-horrible cost in processing time. For those who don't change their sort
order the cost is one comparison. For those who do choose to change their
sort order, there is a (potentially large) array to be reversed, but that
presumably small population has specifically stated they want that order and
it'd be nice to give it to them.
That said, I'd personnaly like to see the default sort order put back to
ascending, with descending being the option. This avoids backlash at the
volume of changes to the website.
I would be happy to add this "my php.net" setting now, but I don't have the time in the coming 3 weeks to play with this. I will have the time after my exams end. BTW there are ready functions to get/set my php.net preferences, so all the settings are stored in one cookie. It is important to keep the cookies number low. We currently have 4-5 cookies, and 20 is the maximum. You see how simple things would add new cookies. So if someone is going to try and add this feature, please use the my php.net functions defined in prepend.inc (and used in my.php and elsewhere), so we won't be dealing with some BC code to convert from old cookie names to new preference methods...
Goba