Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Connie DeCinko 931 posts 1160 karma points
    Apr 06, 2011 @ 21:15
    Connie DeCinko
    0

    Sort XSLT Results by Sort Order Set in Back End

    I have some XSLT that creates a submenu of pages below the current page.  When adding a new page, that page appears at the bottom of the list, even though I chose to change the sort order in the back end.

    How can I force the XSLT to use my preferred sort order?

     

  • Chriztian Steinmeier 2798 posts 8788 karma points MVP 8x admin c-trib
    Apr 06, 2011 @ 21:21
    Chriztian Steinmeier
    0

    Hi Connie,

    I seem to remember this being related to a bug with not republishing the XML cache - which version of Umbraco are you using?

    If you're doing a <xsl:for-each> you can shove a <xsl:sort> in there, and use the @sortOrder attribute (but if that doesn't get updated you're still toast, though)...

    <xsl:for-each select="...">
        <xsl:sort select="@sortOrder" data-type="number" order="ascending" />
    </xsl:for-each>

    /Chriztian 

  • Connie DeCinko 931 posts 1160 karma points
    Apr 06, 2011 @ 21:23
    Connie DeCinko
    0

    I'll give the @sortOrder a try.  I am seeing the behavior indicated in both v.4.5.2 and v.4.7.

     

Please Sign in or register to post replies

Write your reply to:

Draft