MyBB Community Forums

Full Version: posts display in reverse order
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
hello,
i am very pleased so far with myBB installation everything has gone smoothly. i am now trying out ways to get my forum working how i would like it.

an important thing for one of my forums is one of my threads displays posts in reverse order. so that latest posts are displayed at the top of the thread and older posts are pushed down.

is there a way of doing this?
Admin control panel > Manage forums > Edit (the forum you want to apply this to) > Next to "Default Sort Order" select "ascending"
Jeff Wrote:Admin control panel > Manage forums > Edit (the forum you want to apply this to) > Next to "Default Sort Order" select "ascending"

thanks jeff
i have tried doing what you say and selected "sort order" "ascending" but that changes only the order of the threads and not the order of posts in the thread. i would like to be able to acheive the opposite and have the threads remain in the same order but have the posts/replies in a thread in the reverse/ascending order.

any idea how to do this?

i am not making a torrent forum but i would like a similar layout as most torrent boards use, where the latest post stay at the top of the thread.
Sorry, I didn't read your post carefully. To compensate for that Toungue, I've created a plugin that'll do the trick for ya.

It overwrites the existing MyBB query where it calls out threads chronologically. This plugin does reverse chronological order. I made it so the first post of the thread remains at top, though.
hey thats great! i think there may be something wrong though, when i activate this plug-in it turns my opening post pink. but it does what i want to do and my posts are reversed. i think it is good that the opening post stays at the top too. that is useful.

would there be a way to apply this to just one thread. as i assume it is a global modification at present.

thanks for all your help
;o it shouldn't turn anything pink..

Anyways, the new file only applies to a single thread. open it up and find the number 20. Replace it with whatever thread's id you only want to apply this reverse order to.
that works great! i still get pink opening post but i think that might be to do with my theme settings for sticky posts.

so the first plug-in is a global mod and the second plug-in is a thread specific mod?

would i be able to add more than one thread id to this?

thanks jeff
Here it is.. This one combines everything by using a setting.. So in the setting box, set 0 if you want global. Set a tid if you only want a thread. Set multiple tids (separated by commas) if you want certain threads.
When I try to activate your plugin I receive this error message:

Fatal error: Call to undefined function rebuild_settings() in forum/inc/plugins/showthreadreverse.php on line 53

It'a about
	rebuild_settings();
line which is not defined (in function showthreadreverse_deactivate() and function showthreadreverse_activate())?
Sad
Haven't looked at anything, but try removing the "_", ie:
    rebuildsettings();
Pages: 1 2