On August 7, 1998 at 16:02, Oliver Hauser wrote:
i have a mailing list archive (thread index!) wich is
sorted by date. the first mail, which was ever sent to
to list is the first mail in the list.
i want the thread index so, that the newest mails
are on the first page; that means, i want the reverse sort
Not exactly. More accurate: You want threads with the newest messages
to be listed at the beginning of the thread index. See below for
more on this.
the <SORT> tag didn't work, same result as before.
<SORT> only affects the main index. Thread related resources start
with a "T". BTW, there is nothing to do what you want. TREVERSE is
close, but I think using it has problems with MULTIPG active.
A thread listing (which is a tree) always starts with the first message
in the thread and all descendents are listed below it. Note, there is
no reasonable way to "invert" the tree to have the leaf nodes (most
recent message listed at the top). Why? There can be mulitple leaves
at different levels. There is no simple way to represent this kind
of structure in HTML.
This is why I rephrased your request. I.e. Can threads with the
more recent messages be listed at the beginning of the thread index?
Each thread will still be started by the first message, but the listing
order is determine by descendents (note, TREVERSE is only based on
the root nodes of threads).
Supporting this is possible (via code changes), but not trivial.
First, each new message added would require a "walk up" the thread tree
to find the root of thread, and then mark it (with the new message's
date). When doing the sort for printing the thread, base the sort on
the "marks" to determine printing order.
Note, the "walk" operation can degrade performance, especially when
having to deal with subject based threads. What the performance hit
may be I am unsure since the code does not exist. I would guess it
would be significant if processing many messages at one time.
Another penalty is that you basically will be forcing a regeneration
of thread index pages (if MULTIPG is active) everytime new messages
are added. Although doing a regeneration of all thread index pages is
still possible now (due to the nature of threads), the probability
of it happening is not as high (ie. not %100).
An alternative is to provide a reverse sorted chronological index along
with the thread index. Users of the archive can then use the reverse
date index to see what are the newest messages, and from there, easily
navigate to the thread.
Earl Hood | University of California: Irvine
ehood(_at_)medusa(_dot_)acs(_dot_)uci(_dot_)edu | Electronic
http://www.oac.uci.edu/indiv/ehood/ | Dabbler of SGML/WWW/Perl/MIME