We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 7231
    • 4,205 Posts
    &rowTpl=`myrowTpl` &hereTpl=`hereTpl`
    Remember that the rowTpl and the hereTpl names need to match what you named the chunks you used.
    To get the children we need to add the innerRowTpl and innerHereTpl to be the same as the rowTpl and hereTpl. My fault, I forgot about this shocked

    So your call could look like:
    [!Wayfinder? &startId=`0` &rowTpl=`myrowTpl` &hereTpl=`myhereTpl` &innerRowTpl=`myrowTpl` &innerHereTpl=`myhereTpl` !]

    Give this a go and see if it works.

    Please note that you need to use the correct names for the chunks you use for the Tpl’s, and use the startId for the correct location that encapsulates the documents for the menu.


      [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]
      • 32614
      • 65 Posts
      hey dev_cw (aka my savior),

      thanks for your tips. but unfortunately still no dice. selected children still show up as unselected nav items. and the parents of selected children also show up as unselected.

      let me recap what i’ve got going on over here.

      i have two chunks. the first is myrowTpl and it contains this:

      <li class="unselected"><a href="[+wf.link+]" title="[+wf.title+]">[+wf.linktext+]</a>[+wf.wrapper+]</li>


      the second is myhereTpl and it contains this:

      <li class="selected"><a href="[+wf.link+]" title="[+wf.title+]">[+wf.linktext+]</a>[+wf.wrapper+]</li>


      then in my template i call Wayfinder this way:

      [!Wayfinder? &startId=`0` &rowTpl=`myrowTpl` &hereTpl=`myhereTpl` &innerRowTpl=`myrowTpl` &innerHereTpl=`myhereTpl` !]



      anything jump out at you as explaining why child items don’t show up as selected?

      and, of course, ideally would be if selected children showed up in the "selected" class, as well as their parents also showing up as "selected".

      thanks so much for your patience with me!
        "A great democracy must be progressive, or soon it shall cease to be great, and soon it shall cease to be a democracy." -Theodore Roosevelt
        • 7231
        • 4,205 Posts
        OK, I needed to install a local copy and get my hands dirty to test this but I think I got it. This is the result I get:
        <ul>
        <li class="unselected"><a href="/index.php?id=1" title="Home">Home</a></li>
        <li class="unselected"><a href="/index.php?id=2" title="Blog">Blog</a></li>
        <li class="selected"><a href="/index.php?id=15" title="MODx Features">Features</a>
        <ul>
        <li class="unselected"><a href="/index.php?id=16" title="Ajax">Ajax</a></li>
        <li class="selected"><a href="/index.php?id=22" title="Menus and Lists">Menus and Lists</a></li>
        <li class="unselected"><a href="/index.php?id=14" title="Content Management">Manage Content</a></li>
        <li class="unselected"><a href="/index.php?id=24" title="Extendable by design">Extendability</a></li>
        </ul>
        </li>
        <li class="unselected"><a href="/index.php?id=33" title="Getting Help">Getting Help</a></li>
        <li class="unselected"><a href="/index.php?id=39" title="Template Examples">Templates</a>
        <ul>
        <li class="unselected"><a href="index.php?id=39" title="MODxHost">MODxHost</a></li>
        <li class="unselected"><a href="/index.php?id=42" title="MODxCSS Wide">MODxCSS Wide</a></li>
        <li class="unselected"><a href="/index.php?id=43" title="MODxCSS">MODxCSS</a></li>
        </ul>
        </li>
        <li class="unselected"><a href="/index.php?id=32" title="Design">Design</a></li>
        <li class="unselected"><a href="/index.php?id=6" title="Contact Us">Contact us</a></li>
        </ul>


        Notice that the parent "Features" and the child "Menus and Lists" have the class of selected and all the rest are unselected.

        I used the same two chunks myrowTpl and myhereTpl. And added the &activeParentRowTpl parameter with the myhereTpl or selected state template. Here is the wayfinder call I used:

        [!Wayfinder? &startId=`0` &rowTpl=`myrowTpl` &hereTpl=`myhereTpl` &innerRowTpl=`myrowTpl` &innerHereTpl=`myhereTpl` &activeParentRowTpl=`myhereTpl`!]


        myrowTpl:
        <li class="unselected"><a href="[+wf.link+]" title="[+wf.title+]">[+wf.linktext+]</a>[+wf.wrapper+]</li>


        myhereTpl:
        <li class="selected"><a href="[+wf.link+]" title="[+wf.title+]">[+wf.linktext+]</a>[+wf.wrapper+]</li>


        This should work, let us know what happens.
          [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]
          • 32614
          • 65 Posts
          happy day!! that worked like a champ!

          you guys in this forum are amazing!

          thank you so much.

          now that the nav works, i’m going to have to ask some more questions. perhaps i should start a new thread tho, since they won’t be related to my nav...

          thanks again!
            "A great democracy must be progressive, or soon it shall cease to be great, and soon it shall cease to be a democracy." -Theodore Roosevelt