vForums Support > vForums :: Support :: > Messages

Messages - Posted By kyoshi (kyoshi) on 5th Jun 08 at 8:47pm
Where do I find the settings in admin to set messages in descending or ascending order by date?

{Smile}

Re: Messages - Posted By Michael (wrighty) on 5th Jun 08 at 9:12pm
Messages as in PMs?

They automatically ordered Newest to Oldest... {Smile}

Re: Messages - Posted By kyoshi (kyoshi) on 5th Jun 08 at 10:07pm
No, I mean messages on the message board? My message board shows the oldest post first then goes down to the newest post. I'd like to be able to set the messages so that the newest message is first then goes down to the oldest.

Re: Messages - Posted By Michael (wrighty) on 5th Jun 08 at 10:16pm
the newest is first. The oen with the most recent reply! {Smile}


Board Link?

Re: Messages - Posted By kyoshi (kyoshi) on 5th Jun 08 at 10:21pm
http://budo.vforums.co.uk check out the message 'Professor Arrived' (in the 'Martial Arts Discussion' board) and you'll see what I mean.

Re: Messages - Posted By Ross (admin) on 5th Jun 08 at 11:11pm
Hi. Any topics which are either "Sticky" or "Announcements" remain at the top of the board above all other topics. Looking at that board, the topic you mentionned appears as the first standard (non-sticky) topic. You can have it appear above the "Welcome" topic by unstickying the welcome topic (if that's what you want) {Smile}

Re: Messages - Posted By kyoshi (kyoshi) on 5th Jun 08 at 11:24pm
No, I'm not talking about topics, i understand the sticky... I'm talking about messages (replies), for example...

message blah blah 5th July 2008

message blah blah 9th July 2008

The 9th July message (the newest) is at the bottom and the oldest message is at the top. I'd like to be able to admin my settings to have 9th July message (newest) above the 5th July message.

{Grin}

Re: Messages - Posted By Marc (cr0w) on 6th Jun 08 at 3:15am
The system is designed to automatically sort from newest to oldest. Most likely what happened is that someone replied to that topic then deleted their post, causing it to remain at the top. Have a look at your Security Records and/or Recycle Bin to see if that's the case. {Smile}

Re: Messages - Posted By Nick (nickb) on 6th Jun 08 at 3:56am
Or if in general Kyoshi wants the newest Post at the top, like my post will be at the bottom as it is the newest post. And I think Kyoshi wants the newest post at the top instead of the bottom.
(this is what I am getting. This is just my guess. {Tongue Out} )

Re: Messages - Posted By Marc (cr0w) on 6th Jun 08 at 4:29am
Ohh, you're meaning that you want to be able to choose if within a topic itself the replies are sorted from newest to oldest. I understand now. {Tongue Out}

This is [as far as I'm aware] currently not available, but who knows, maybe Ross will feel like adding this. {Wink}

Re: Messages - Posted By Ross (admin) on 6th Jun 08 at 5:40pm
Hi again,

I don't think it'd be beneficial to have this as a built in feature at this time. However, you can place this code into your global footer which should do what you want {Smile}

Code: JavaScript
 
  1. <script type="text/javascript">
  2. <!--
  3. /* Reverse Post Order in Topic
  4. Written for vForums
  5. http://virtualforums.co.uk */
  6.  
  7. if(location.href.match(/action\/view_topic(\/|$)/gi)) {
  8.     var td = get('td', TAG);
  9.     var posts = Array();
  10.     var posts_holder = false;
  11.     for(i=0; i<td.length; i++) {
  12.         if(td.item(i).id && td.item(i).id.match(/^post-/)) {
  13.             posts.push(td.item(i).parentNode);
  14.             if(!posts_holder) {
  15.                 posts_holder = td.item(i).parentNode.parentNode;
  16.             }
  17.         }
  18.     }
  19.     if(posts_holder) {
  20.         posts.reverse();
  21.         for(p=0; p<posts.length; p++) {
  22.             posts_holder.appendChild(posts[p]);
  23.         }
  24.     }
  25. }
  26. //-->
  27. </script>