Jump to content


Problem sorting NewsListing


  • You cannot reply to this topic
2 replies to this topic

#1 The Bearded One

    Etomite Forum Newbie

  • Member
  • 14 posts

Posted 06 November 2004 - 06:40 PM

I am trying to use the NewsListing snippet to list information about speakers who talk before a weekly forum.

What I am trying is very similar to what hmueller wrote about in his entry "NewsListing - sorting of". Unfortunately, I can't figure out what he did to make his work.

I need to be able to control the order documents in a folder are displayed by the NewsListing snippet.

The easiest way to do that would seem to be to do a sort by Title.

I've played around with the code, but nothing I've tried works.

Any suggestions that might get me headed in the right direction would be greatly appreciated.

Thanks.

Gary

#2 Mr. Tech

    Etomite Forum Fan

  • Member
  • Pip
  • 65 posts

Posted 06 November 2004 - 08:08 PM

The Bearded One, on Nov 6 2004, 12:40 PM, said:

...I need to be able to control the order documents in a folder are displayed by the NewsListing snippet.
The easiest way to do that would seem to be to do a sort by Title.
I've played around with the code, but nothing I've tried works.
I have sorted my news items by changing the following line:

$resource = $etomite->getAllChildren($resourceparent, 'unpub_date', 'ASC', $fields='id, pagetitle, unpub_date, longtitle, description, createdon, createdby');
In this case, I am sorting my news items by the 'unpub-date' (unpublish date of the document) and the sort method is 'ASC' (ascending).

Hope this helps...

#3 The Bearded One

    Etomite Forum Newbie

  • Member
  • 14 posts

Posted 07 November 2004 - 07:22 PM

Mr. Tech,

That worked!

Thanks

Gary





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users