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

    i just found out, that when I’m adding a whitespace in the wayfinder call between "Wayfinder?" and "startId=`0`", like it is shown in every example, the generated menu isn’t right. It will then just show the active nested ul and not the surrounding ul’s.
    The standard wayfinder calls in the modx templates are without whitespaces as well. Does anybody know why this happens?

    my wayfinder call is:
    [!Wayfinder?startId=`0` &hereClass=`current` &selfClass=`active` &level=`3` &outerClass=`topnav`!]


    thank you & cheers, j
      • 5340
      • 1,624 Posts
      shouldn’t it be [!Wayfinder? &startId=`0`.....
        • 7231
        • 4,205 Posts
        I think it is a good idea to always use a space and the & in the snippet calls:
        [!Wayfinder? &startId=`0` &hereClass=`current` &selfClass=`active` &level=`3` &outerClass=`topnav`!]

        I know what you mean by the tutorials and even some of the documentation leaving out the witespace, but I think it is not a good practice.

        If you want to twist your brain look at examples in the ListIndexer documentation:
        [[ListIndexer?LIn_dir=ASC&LIn_sortBy=menuindex]]
        No whitespace and no backticks? Will this work like this? I think that some of these may be old examples in the days before these things made a difference.
          [font=Verdana]Shane Sponagle | [wiki] Snippet Call Anatomy | MODx Developer Blog | [nettuts] Working With a Content Management Framework: MODx

          Something is happening here, but you don't know what it is.
          Do you, Mr. Jones? - [bob dylan]
          • 26931
          • 2,314 Posts
          Hi dev_cw!

          hahaaa smiley of course, you’re right....oh dear, i guess i should get off that computer for today, can’t think straight any more.

          thanks again, j
            • 26931
            • 2,314 Posts
            ...and of course thank you xpix as well! cheers, j