We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 24694
    • 4 Posts
    Hi there,
    First of all I have to say that I’m new in modx...but I LOVE IT!! smiley

    Apologies for the stupidity of my post but I found similar articles to solve my problem but still cant figure it out what’s the best solution for my needs.

    I’m building my personal portfolio.. I’m using wayfinder to pull out the top main navigation..and all work fine..

    [[Wayfinder? &startId=`0` &outerTpl=`main-menu-container` &level=`1`]]


    In one of my top navigation link called WORK I’ve got a sub navigation to show my portfolio WEB | PRINT | IDENTITY etc etc





    I m not sure if I have to use another simple wayfinder changing the &level=`` number or use the [Snippet] UltimateParent...also should I include the Resources of my sub navigation into the WORK resource?

    At the moment I’m using just [[~id]] to pull out the page.

    [[$meta]]
    		<ul id="work-navigation">
                <li><a href="[[~18]]" title="Web">Web</a></li>
                <li><a href="[[~14]]" title="Identity">Identity</a></li>
                <li><a class="active" href="[[~15]]" title="Print">Print</a></li>
    			<li><a href="[[~16]]" title="Playground">Playground</a></li>
    			<li><a href="[[~17]]" title="Personal">Personal</a></li>
            </ul>
    		<h1 class="intro-title">Web projects</h1>
    		<!-- <ul class="web-content">
    			[[!getResources?
    				&parents=`14` 
    				&tpl=`print-work-template` 
    				&tvPrefix=``
    				&limit=`9999`
    				&includeTVs=`1`
    				&processTVs=`1`
    				&includeContent =`1`
    				&hideContainers=`1`
    				&showHidden=`true`
    			]]					
    		</ul> -->
    	</div>
    </div>
    <a href="#" title="Scroll to Top" id="toTop">Scroll to Top</a>
    [[$footer]]


    I m sorry I know it’s very confusing and my English doesn’t help much...

    Thanks

      • 28042 ☆ A M B ☆
      • 24,524 Posts
      You should be able to use CSS or Javascript to position and display the submenu, using a single Wayfinder call for the main and sub menus using the &hideSubMenus parameter to prevent the generation of the submenu until the user selects your Work menu item. Of course the placement of the submenu would make a CSS hover display impossible, but absolutely positioning the submenu’s container element shouldn’t be a problem.
        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
        • 24694
        • 4 Posts
        Thanks Susan,
        After your comment I menage to to call up the sub menu with another wayfinder code

        [[Wayfinder? &startId=`2` &outerTpl=`sub-menu` &level=`2`]]


        All work fine now!!

        Thanks again