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

    I already made some standard menus with DropMenu and it works without problems. No problems with the styling or so. But now I would like to made a divided menu. But now i have problems with DropMenu undecided

    The situation:

    I have 4 Main sites (MAIN 1-4). The first one have 2 subsites (SUB MAIN 1, SUB MAIN 2). And the first subsite have 4 other subsites (SUB 1.1-1.4).

    I have a template which have a top bar what only contains the RED sites. In my template code i insert this snippet call:
    [[DropMenu? &menuName=`mainMenu` &startDoc=`0` &levelLimit=`1`]]


    The subsites of the RED main sites should be displayed in a seperate container in the template. And this is my problem.
    How can i do this?

    Three examples:

    1) The active site SUB 1.2


    2) And here is the site SUB MAIN 2 active


    3) And when the main site MAIN 3 is active it should looks like this


    I try it with this call:
    [[DropMenu? &menuName=`subMenu` &startDoc=`[*parent *]`]] 

    This works for the example 2 and 3 but not for the first example. But that is logical wink

    Can anybody help me or give a brainstorm? smiley
    Thx alot!!!

    Lupo
      • 10357
      • 573 Posts
      wayfinder has now replaced dropmenu.

        • 32319
        • 129 Posts
        First, use Wayfinder instead of Dropmenu to create your menus. Dropmenu is deprecated.

        Next, in your template, make your submenu snippet call like this:
        [tt][!Wayfinder? &startId=`[[UltimateParent]]!][/tt]

        This will tell Wayfinder to build its menu based the active pages top level folder (i.e. Main1, Main2, Main3, Main4).

        Your top nav snippet call can look like this:
        [tt][!Wayfinder? &startId=`0` &level=`1`!][/tt]

        NOTE: The submenu call must be called un-cached [tt][!...!][/tt] in order for the snippet call nested in a snippet call to work. It is a known issue that should be fixed in 9.7.

        If you don’t have UltimateParent installed get it here:
        http://www.modxcms.com/UltimateParent-643.html
          "Regret for the things we did can be tempered by time; it is regret for the things we did not do that is inconsolable."
          -- Sydney Harris
          • 17691
          • 22 Posts
          Hi!

          Thanks for your fast answer!
          Yes it’s right. I see that only the Wayfinder snippet come with the new release but i think i try it with DropMenu.

          But OK. I will try it with Wayfinder. I hope it is as easy to style and config as the DropMenu wink
          I will the give you a feedback...

          Bye bye
            • 25663 MODX Staff
            • 12,272 Posts
            Wayfinder is infinitely easier to customize from an output perspective, and therefore much easier to style than DropMenu. smiley
              Ryan Thrash, MODX Co-Founder
              Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me