We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 16905
    • 46 Posts
    Hi. I am a novice with Wayfinder and Modx and PHP. I have an image navigation bar, that goes directly to the pages -> ie. Home = [~2~]

    On the ’News’ page, I have a Wayfinder menu for the latest news.

    1) How do I set up the Wayfinder Menu on the news so the most current news (pages) is always at the top of the menu? Right now, it is listing oldest to newest.

    2) Is there a way I can then set up the Image Navigation so that it always lands on the newest News when the user clicks on it?

    Thanks and warm regards,
    Leigh
      • 26016
      • 561 Posts
      Hi Leigh, and welcome!
      It’s somewhat hard to say without seeing the site, but I can give you ideas.

      I’m guessing that you’ll enjoy using the following parameter in the Wayfinder call:
      &sortOrder


      I suspect that this type of parameter will help your call:

      &sortOrder=`DESC`


      Good details about that here:
      http://www.muddydogpaws.com/development/wayfinder/parameters.html

      menuindex is the typical field Wayfinder sorts on. If the above options don’t give you what you want, you have a huge choice of document fields to sort on if you want to get fancy (see same helpful doc above):
      &sortBy

      which works hand-in-hand with &sortOrder.

      Cheers, Dave
        MODx and Wordpress development
        Linux, PHP 5.2, MySQL 5.0, Evo 1.05, Revo 2.08-pl, Firefox 4