miniBB ® miniBB®
miniBB Support Forums
 | Forums | Register | Reply | Search | Statistics | Manual |
Custom Tutorials and Modifications miniBB Support Forums / Custom Tutorials and Modifications /   

Sorting ALL replies in Descending order (latest on top)

Author Mirekk
Registered
#1 | Posted: 8 Feb 2008 17:00 
How to set sorting answers in topic - the most new answer to be on the top. Now I need to scroll down to see new message. I have find

http://www.minibb.com/forums/manual.html#sorthread

but if I change //$themeDesc=array(); to //$themeDesc=array(THREAD_IDs);
nothing happens. My forum is on http://www.elmundo.cz/forum
Thanks for answer.

Author marsbar
Associated Member
#2 | Posted: 9 Feb 2008 01:27 | Edited by: marsbar 
1) uncomment //$themeDesc=array(THREAD_IDs);, so that it reads: $themeDesc=array(THREAD_IDs);.

2) replace THREAD_IDs with the ID number/numbers of the thread/threads (the replies of which) that you would like sorted in descending order. In the following example, replies in thread ID 20 and thread ID 35 are sorted in descending order:
$themeDesc=array(20, 35);.

All the best -
mb

Author Mirekk
Registered
#3 | Posted: 9 Feb 2008 08:04 
Ok, I understad. But where I can find the ID number of thread? I want all answers in all forum sorted - latest on the top.
Mirek

Author marsbar
Associated Member
#4 | Posted: 9 Feb 2008 15:43 | Edited by: marsbar 
Mirekk wrote: But where I can find the ID number of thread?

You find it in the thread's URL. Here is a thread from your Paragliding forum:
http://www.elmundo.cz/forum/index.php?action=vthread&forum=3&topic=13
The ID of the thread is 13 - see the highlighted bit?

Mirekk wrote: I want all answers in all forum sorted - latest on the top.

Oh, I see; in that case, I think the best course of action for you is to wait for advice from miniBB Team/Paul. As far as I know, the method described so far is meant for exceptions.

All the best -
mb

Author Mirekk
Registered
#5 | Posted: 10 Feb 2008 14:46 
I have it. Is working as I wish Thanks. So, i will wait for some answer from Team/Paul, if they will have any idea, how to doo it for all forum.
Mirek.

Author Paul
Lead Developer
#6 | Posted: 11 Feb 2008 05:40 | Edited by: Paul 
Here is how to determine topic ID btw.

I am not sure if it will work for all threads, however you may try to put this under bb_plugins.php:

if(isset($topic) and $topic!=0) $themeDesc[]=$topic;

I've tested this code on my side and it works.

Custom Tutorials and Modifications miniBB Support Forums / Custom Tutorials and Modifications / Sorting ALL replies in Descending order (latest on top) Top

Your Reply Click this icon to move up to the quoted message

 Short link for this topic:

 ?
Only registered users are allowed to post here. Please, enter your username/password details upon posting a message, or register first.


Before posting, make sure your message is compliant with our forum posting rules. If not, it may be locked or deleted with no explanation.
 
miniBB Support Forums Powered by Forum Software miniBB ® Features  Requirements  Demo  Download  Showcase  Gallery of Arts
Compiler  Premium Extensions  Premium Support  License  Contacts
Install the Captcha add-on: protect your miniBB-forums from the automated spam and flood.
Captcha Addon for miniBB