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

    Simple question i'm sure!
    I have the following code:
    <div id="wrapper-menubar">
    <ul id="menu-bar">
    <li class="current"><a href="#">Home</a></li>
    <li><a href="#">Features</a></li>
    <li><a href="#">Clients</a></li>
    <li><a href="#">Tour</a></li>
    <li><a href="#">Starting off</a></li>
    <li><a href="#">FAQ</a></li>
    <li><a href="#">News</a></li>
    <li><a href="#">Contact Us</a></li>
    </ul>
    </div>


    And i added Wayfinder like this:
    <div id="wrapper-menubar">
    <ul id="menu-bar">
    	[!Wayfinder?startId=`0`!]
    </ul>
    


    For some reason my menu doesn't show and when i view the source i see the following:
    <ul id="menu-bar">
    <ul>
    <li class="active"><a href="modx/" title="Home" >Home</a></li>
    <li><a href="/modx/index.php?id=2" title="Blog" >Blog</a></li>
    <li><a href="/modx/index.php?id=15" title="MODx Features" >Features</a><ul><li><a href="//index.php?id=16" title="Ajax" >Ajax</a></li>
    <li><a href="/modx/index.php?id=22" title="Menus and Lists" >Menus and Lists</a></li>
    <li><a href="/modx/index.php?id=14" title="Content Management" >Manage Content</a></li>
    <li class="last"><a href="/modx/index.php?id=24" title="Extendable by design" >Extendability</a></li>
    </ul>
    </li>
    <li><a href="/modx/index.php?id=33" title="Getting Help" >Getting Help</a></li>
    <li><a href="/modx/index.php?id=32" title="Design" >Design</a></li>
    <li class="last"><a href="/modx/index.php?id=6" title="Contact Us" >Contact us</a></li>
    </ul>
    </ul>
    </div>
    


    Wayfinder seems to be adding extra opening and closing ul's.
    Is it possible that it's causing my menu not to show.

    please help
    Thanks
      • 40092
      • 265 Posts
      Wayfinder does put the <ul> tags in there by itself, so no need to do that by yourself.
      You would however may want to style it, so why not make your ul id a div, for example.
      Or if you do your styling in the upper div already, then remove the <ul> tags completely.

        • 28042 ☆ A M B ☆
        • 24,524 Posts
        The default outerTpl is what sets that outer ul container. You can adjust that in any way you like, as long as you have the [[+wf.wrapper]] placeholder to insert the rest of what Wayfinder generates.
          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
          • 42189
          • 7 Posts
          Thanks everyone, i went ahead and adding my styling to the upper div