We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 40786
    • 6 Posts
    Hello!
    I have a problem with wayfinder.
    When called:
    [[Wayfinder? & startId = `0`]]

    It finds all resources, including those that I need.
    I also need to make a withdrawal of all resources in the "catalog" (ID = 5).
    I therefore call:
    [[Wayfinder? & startId = `5`]]

    After that, do not get any result (empty)
    In what may be the problem?
      • 28042 ☆ A M B ☆
      • 24,524 Posts
      Try it without all the spaces
      [[Wayfinder? &startId=`5`]]
        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
        • 40786
        • 6 Posts
        [[Wayfinder? &startId=`5`]]

        It's not work
          • 28042 ☆ A M B ☆
          • 24,524 Posts
          That is the ID of the parent resource? You want to make a menu out of its children? Is it (and its children) published? Set to show in the menu?
            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
            • 40786
            • 6 Posts
            That is the ID of the parent resource? - yes.
            You want to make a menu out of its children? - yes, and it subchildrens.
            Is it (and its children) published? - yes.
            Set to show in the menu? - yes.

            See screenshots:

            I use Group Edit plugin for manage categories and goods
              • 40786
              • 6 Posts
              Can you help me?
                • 10208 ☆ A M B ☆
                • 1,780 Posts
                Assuming you're using HTML5...

                Try this:

                <nav id="bmenu">
                [[Wayfinder? 
                &startId=`5` 
                &level=`0` 
                &rowTpl=`rowTpl` 
                &innerTpl=`innerTpl` 
                &hideSubMenu=`0`]]
                </nav>


                Setting &level=`0` lets the menu show all children. If you want to limit it to 4 levels for some reason (assuming you have more than 4 levels), you can use the &level parameter to 4 but defaulting to 0 shows all levels by default.

                You can style the rowTpl and innerTpl with the bmenu as an ID, and bmenu2 as the sublist class, i.e.:

                nav#bmenu ul { }
                
                nav#bmenu ul li ul.bmenu2{ }


                create "rowTpl" chunk:
                <!-- rowTpl -->
                <li[[+wf.id]] class="[[+wf.classnames]]">
                <a href="[[+wf.link]]" title="[[+wf.title]]" [[+wf.attributes]]>[[+wf.linktext]]</a>
                [[+wf.wrapper]]
                </li>


                create "innerTpl" chunk:
                <!-- innerTpl -->
                <ul class="bmenu2 [[+wf.classnames]]">
                [[+wf.wrapper]]
                </ul>


                [ed. note: frogabog last edited this post 14 years, 2 months ago.]
                  Frogabog- MODX Websites in Portland Oregon
                  "Do yourself a favor and get a copy of "MODX - The Official Guide" by Bob Ray. Read it.
                  Having server issues? These guys have MODX Hosting perfected - SkyToaster
                  • 40786
                  • 6 Posts
                  Not work.
                  Result is empty:(