We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 15871
    • 105 Posts
    I have a Wayfinder call that I need to function differently depending on what level the document is in the hierachy. What I need to do is be able to define with the document is 2 levels down, 3 levels down, etc. I really would like to do this dynamically instead of a TV to manually define it at the document level.

    Thanks in Advance smiley
      • 28042 ☆ A M B ☆
      • 24,524 Posts
      Use the &levelClass parameter; use whatever name you would like; Wayfinder will add the number to it:
      [[Wayfinder? ... &levelClass=`level` ...]]

      Now the [+classnames+] placeholder will contain level1, or level2, etc.
        Studying MODX in the desert - http://sottwell.com
        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
        Join the Slack Community - http://modx.org
        • 15871
        • 105 Posts
        Thanks Susan,

        How can I use that within a PHx statement though so I can swap out a different &startId and &level based on the &levelClass?