Reversing the order of replies. (General)

by mrmagee, Friday, February 13, 2009, 17:50 (5549 days ago)

Last question for the time being -- I set this up in a sandbox environment last night after Alex's response to me, and so far I'm loving it (we've made some changes in look to suit our purpose). The one thing that we're struggling with a bit is that we would like for the most recent replies to a post to show at the top of the reply chain (versus the bottom as is currently implemented) all the way down the reply tree. It looks like we're going to have to make edits to entry.tpl.inc, and most likely another file as well.

Has anyone implemented this in this manner before?

Avatar

Reversing the order of replies.

by Alex ⌂, Friday, February 13, 2009, 19:56 (5549 days ago) @ mrmagee

Hi,

did I get it right and you want it like this?

  • Posting
    • Second reply
    • First reply

If so you need to replace "ASC" by "DESC" in includes/index.inc.php on line 85 ($thread_result = @mysql_query("SELECT ... ORDER BY time ASC", ...) and in thread.inc.php on line 77.

Alex

Reversing the order of replies.

by mrmagee, Friday, February 13, 2009, 21:15 (5549 days ago) @ Alex

Alex,

You had it right -- that works for the front page, but when one is going to reply to a post, it still shows up in the opposite order. Thank you for all your help -- this system is great.

Avatar

Reversing the order of replies.

by Alex ⌂, Saturday, February 14, 2009, 09:18 (5548 days ago) @ mrmagee

You had it right -- that works for the front page, but when one is going to reply to a post, it still shows up in the opposite order.

Yes, I forgot this one: includes/entry.inc.php, ~ line 140:

replace
WHERE tid = ".$thread.$display_spam_query_and." ORDER BY time ASC
by
WHERE tid = ".$thread.$display_spam_query_and." ORDER BY time DESC

Alex

RSS Feed of thread