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

    I use Wayfinder 1.0 as follows:
    [!Wayfinder? &startId=`[[UltimateParent? &topLevel=`2`]]` &outerTpl=`wfOuter` &rowTpl=`wfRow` &innerTpl=`wfInner` &innerRowTpl=`wfInnerRow` &level=`3` &hereTpl=`wfCurrent` &activeParentRowTpl=`wfParent`!]

    Everything works perfect, except I want the inner <ul> of the active tree only to have a specific class in the <ul> tag

    My WfInner chunk =
    <ul>
    [+wf.wrapper+]
    </ul>


    But it seems that there is no template parameter to set the <ul> like in hereTpl. My hereTpl =
    <li id="cursub"><a href="[+wf.link+]">[+wf.linktext+]</a>[+wf.wrapper+]</li>

    is it possible to add a class only to the ective tree <ul>??

    Thx!!
      • 7231
      • 4,205 Posts
      If you include the wf.classes wayfinder will add a class to the current <ul>

      <ul[+wf.classes+]>
      	[+wf.wrapper+]
      </ul>


      This will add the active state to the <ul> only if it is currently active
        [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&#39;t know what it is.
        Do you, Mr. Jones? - [bob dylan]
        • 2896
        • 70 Posts
        hmm, you were right about that [+wf.classes+] I thought ... But it doesn’t seem to set the active class to the <ul> tag? Within <li> tags it is correctly set but not in <ul>

          • 28042 ☆ A M B ☆
          • 24,524 Posts
          You should be able to work that out in the CSS with something like
          li.active ul {
            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