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

    I have this problem with getting a submenu right in the navigation menu of a site I’m building.
    The problem is that it won’t show the submenu.

    You can check the website here: http://www.kwestievan.nu
    Under ’weekmenu’, a submenu is available. However, this is not shown on hovering over weekmenu, as I expect it to.

    For the navigation, I use Wayfinder in a pretty straightforward way. Here is the template including the Wayfinder call:

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
    <head>
      <meta http-equiv="content-type" content="text/html; charset=utf-8" />
      <meta name="description" content="Your description goes here" />
      <meta name="keywords" content="your,keywords,goes,here" />
      <meta name="author" content="Your Name" />
       <base href="[(site_url)]"></base>
      <link rel="stylesheet" type="text/css" href="assets/templates/andreas00/andreas00.css" media="screen,projection" />
      <title>[*pagetitle*] - A free website template by Andreas Viklund modified by Bright Byte for Kwestie Van</title>
    
    
    
     [*hideSidebar*]
    </head>
    
    <body>
    <div id="wrap">
    	<div id="header">
    		<h1><a href="#">[*pagetitle*]</a></h1>
    		<p><strong>[*longtitle*]</strong></p>
    	</div>
    
           <div id="lefttop">
           <div>
    
    	<div id="leftside">
    		<h2 class="hide">QST menu:</h2>
    		[[Wayfinder? &startId=`0` &level=`2` &displayStart=`1` &startItemTpl=`startItem` &outerTpl=`outer` &selfClass=`current` &rowTpl=`row` ]]
    	</div>
            <div id="leftbottom">
            </div>
    
    <div id="contenttop">
    </div>
    
        <div id="content">
    		[*content*]
    	</div>
    
    <div id="contentbottom">
    </div>
    
    <div id="footerPicsTop">
    </div>
    <div id="footerPics">
    </div>
    <div id="footerPicsBottom">
    </div>
    	<div id="footer">
    		{{footer}}
    	</div>
    
    </div>
    </body>
    </html>
    


    Further on, here is the CSS code for the navigation part:

    #leftside {float:left; background-color:#5eddc0; background:url(img/navbck.jpg) repeat-y top center; margin-top:35px; padding:0; width:220px; height:400px;}
    #leftside ul {list-style:none; margin:0 0 18px; padding:0; width:150px;}
    
    #leftside a {color:#505050; float:left; font-size:1em; font-weight:700; margin-bottom:5px; padding:5px 1px 5px 5px; text-decoration:none; width:138px;}
    #leftside a:hover,#leftside ul li a.current {background-color:#5eddc0; color:#505050;}
    #leftside ul ul {display:none; position:relative; left:100px; font-size:0.9em; margin:0 0 0 15px; padding:0 0 5px 0; width:133px;}
    
    #leftside ul ul:hover li {display: block;}
    #leftside ul ul ul {font-size:1em; width:120px;}
    #leftside ul ul ul a {width:108px;}
    #leftside h2 {font-size:1.5em; font-weight:400;}
    
    #leftside p,.announce p {font-size:0.9em;} */


    When I comment out the line

    #leftside ul ul:hover li {display: block;}


    And remove the "display:none;" from the #leftside ul ul line, The whole menu, including submenu’s is shown.

    How can I achieve that the submenu is shown on hovering the navigation menu ’weekmenu’ ?

    Cheers,
    Unforgiven.

      • 28042 ☆ A M B ☆
      • 24,524 Posts
      What browser? IE6 does not support the :hover pseudo-class for anything except <a> tags.
        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
        • 31051
        • 23 Posts
        I’ve been testing in Firefox 3.5 - 3.6
          • 28042 ☆ A M B ☆
          • 24,524 Posts
          Try fixing these first (you can ignore the error relating to the target="_blank" nonsense).
          http://validator.w3.org/check?uri=http%3A%2F%2Fwww.kwestievan.nu%2F&charset=%28detect+automatically%29&doctype=Inline&group=0

          After that, looking at the View Source, there isn’t anything under "weekmenu". Are you sure there are documents under it in the Tree?

          [[Wayfinder? &startId=`0` &level=`2` &displayStart=`1` &startItemTpl=`startItem` &outerTpl=`outer` &selfClass=`current` &rowTpl=`row` ]]


          &displayStart and &startItemTpl have no meaning when the startId is 0; there’s nothing there to display.

          Do you have the [+wf.wrapper+] placeholder in your rowTpl?

            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
            • 31051
            • 23 Posts
            OK, So I’ve modified the Wayfinder entry. Now you can see the submenu’s in the View Source, but still no floating submenu...

            Haven’t fixed the errors from the validator though...will do so tonight.
              • 28042 ☆ A M B ☆
              • 24,524 Posts
              I still see this in a View Source (no submenu)
              <ul><li class="active current"><a href="http://www.kwestievan.nu/" title="MODx CMS Install Success" >Base Install</a></li>
              <li><a href="/index.php?id=2" title="home" >home</a></li>
              <li><a href="/index.php?id=3" title="weekmenu" >weekmenu</a></li>
              
              <li class="last"><a href="/index.php?id=4" title="Test3" >Test3</a></li>
              </ul>
              
                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
                • 31051
                • 23 Posts
                That is very strange huh huh ....this is what I see in both Firefox 3.6 and IE8:

                	<div id="leftside">
                		<h2 class="hide">QST menu:</h2>
                		<ul>
                                    <li><a href="http://www.kwestievan.nu/" title="MODx CMS Install Success" >Base Install</a></li>
                                    <li><a href="/index.php?id=2" title="home" >home</a></li>
                                    <li class="active current"><a href="/index.php?id=3" title="weekmenu" >weekmenu</a>
                                        <ul>
                                           <li><a href="/index.php?id=6" title="sub1" >sub1</a></li>
                                           <li class="last"><a href="/index.php?id=7" title="sub2" >sub2</a></li>
                                        </ul>
                                    </li>
                                    <li class="last"><a href="/index.php?id=4" title="Test3" >Test3</a></li>
                                </ul>
                	</div>
                


                The sub1 and sub2 are the submenu’s.

                cheers,
                Unforgiven
                  • 28042 ☆ A M B ☆
                  • 24,524 Posts
                  Are we still talking about the same URL you posted in the first post?
                    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
                    • 31051
                    • 23 Posts
                    Yes, we are still talking about the same URL: http://kwestievan.nu.

                    And now I am at another location(work), I don’t see the submenu’s either....very strange....
                      • 28042 ☆ A M B ☆
                      • 24,524 Posts
                      Are the child pages published? Assigned to a document group? There are a number of situations where a logged-in manager user can see things that an ordinary visitor can’t.
                        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