We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 22840
    • 1,572 Posts
    Hi All,

    I’m having a propper blond day today and can’t seem to get the sort order for ditto to work, Heres my call

    [!Ditto? &tpl=`site-list` &parents=`10` &orderBy=`pagetitle DESC` &paginate=`1` &paginateAlwaysShowLinks=`0` &summarize=`10`&extenders=`star_rating`!] 


    Now if I change the sort order to ASC nothing changes in the display on the page:

    [!Ditto? &tpl=`site-list` &parents=`10` &orderBy=`pagetitle ASC` &paginate=`1` &paginateAlwaysShowLinks=`0` &summarize=`10`&extenders=`star_rating`!] 


    I have 2 docs one called Celaeron Caravan And Camp Site and the other is Aeron Coast Caravan Park. I need to get them to display alphabetically by page title but no matter what I put in the call there not.

    Just to add the page is called un-cached so it’s not that an the pagetitles are as above.

    Any points would be great
      • 4310
      • 2,310 Posts
      Are you using MySQL 5.0.51 by any chance?
        • 22840
        • 1,572 Posts
        Hi bunk58,

        Thanks for replying.

        According to my Cpanel I’m using MySql 5.0.67-community
          • 4310
          • 2,310 Posts
          That’s one theory dead in the water wink
          Have you tried another field e.g.
          &orderBy=`menuindex ASC`

          to check if any ordering works?
            • 22840
            • 1,572 Posts
            Just tried that using &orderBy=`menuindex ASC` and &orderBy=`menuindex DESC` and both results are the same, also cleared the cache ( just incase ) and cleared my browser cache and a hard refresh but no change at all. As stated the page that is returning the results is un-cached as is the call.

            Thanks for helping out
              • 4310
              • 2,310 Posts
              Have you tried a cached Ditto call on an un-cached page, or vice versa?
                • 26931
                • 2,314 Posts
                anonymized-26931 Reply #7, 17 years ago
                which version of Ditto are you using? maybe try &sortBy and &sortDir?
                  • 22840
                  • 1,572 Posts
                  Quote from: bunk58 at Sep 20, 2009, 08:17 AM

                  Have you tried a cached Ditto call on an un-cached page, or vice versa?
                  Just tried that and still the same huh

                  Using Ditto 2.1 and using &sortBy=`pagetitle` &sortDir=`ASC` gives the same results as &sortBy=`pagetitle` &sortDir=`DESC`

                  thanks again for trying, it’s driving me mad.......
                    • 26931
                    • 2,314 Posts
                    anonymized-26931 Reply #9, 17 years ago
                    try it with a very simple call, like
                    [!Ditto? &parents=`10` &orderBy=`pagetitle ASC`!]
                    if it works, add your parameters one by one to see when it breaks
                      • 22840
                      • 1,572 Posts
                      Great shout,

                      Looks like the &extenders=`star_rating` was stopping the sort by !!!!

                      Really need to find a fix for that now as it displays the star rating for the site and was one of the features I really want >:(

                      Cheers for the help