Note that there are some explanatory texts on larger screens.

plurals
  1. POSubmenu doesn't overflow hidden
    text
    copied!<p>The problem is that when i hover <strong>on the area</strong> where the more link is, the menu appears and it should appear only if i have hovered over the More link, <strong>not on the area</strong>. I tried with <code>overflow:hidden</code> on the sub-menu <code>.ktmsg ul li ul {</code> but doesn't work. I have the below code</p> <p>HTML</p> <pre><code>&lt;div class="ktmsg"&gt; &lt;li&gt;&lt;a id="a0" href="#"&gt; 0 &lt;/a&gt;&lt;/li&gt; &lt;ul&gt; &lt;li class="a1"&gt;&lt;a href="#"&gt; 1 &lt;/a&gt;&lt;/li&gt; &lt;li&gt; &lt;a href="#"&gt;More&lt;/a&gt; &lt;ul&gt; &lt;li class="a4"&gt;&lt;a href="#"&gt; 4 &lt;/a&gt;&lt;/li&gt; &lt;li class="a5"&gt;&lt;a href="#"&gt; 5 &lt;/a&gt;&lt;/li&gt; &lt;li class="a6"&gt;&lt;a href="#"&gt; 6 &lt;/a&gt;&lt;/li&gt; &lt;/ul&gt; &lt;/li&gt; &lt;/ul&gt; &lt;/div&gt; </code></pre> <p>CSS</p> <pre><code>.ktmsg { font-size: 16px; font-weight: normal; margin: 0px; height: 18px; border-top-right-radius: 8px; border-top-left-radius: 8px; width: 930px; padding: 0px; text-align: left; height: 20px; position: relative; font-weight: normal; font-size: 15px; background-color: red; } .ktmsg a{ text-align: center; padding: 13px 4px; white-space: nowrap; float: left; text-decoration: none; background:red; color: #FFF; min-width: 150px; transition: all 0.4s; } .ktmsg ul{ list-style: none outside none; width: 100%; position: relative; padding-left:0px; } .ktmsg li { float:left; position:relative; list-style-type: none; display: inline; padding: 0px; margin: 0px 10px; background-image: none; } .ktmsg li a, .ktmenu li a:active, .ktmenu li a:visited { margin:0px; color: #FFF; border: 0px; text-decoration: none; font-weight: bold; } .ktmsg ul li a:hover { color: blue; text-decoration: none; } .ktmsg a, .ktmsg a:active, .ktmsg a:visited { color: #FFF; margin:0px; padding: 0px; text-decoration: none; } .ktmsg ul li ul { overflow:hidden; padding:0; background:red; opacity:0; height:auto; width:auto; margin-top:25px; position:absolute; transition-property: opacity; box-shadow: 0 0 2px 2px; border-radius: 6px; transition-duration: 1s; transition-timing-function: linear; transition-timing-function: ease-out; } .ktmsg ul li:hover ul{ overflow:visible; display:block; background:red; height:auto; width:auto; margin-top:25px; opacity: 1; box-shadow: 0 0 2px 2px; border-radius: 6px; } .ktmsg ul li ul li{ background:red; padding: 10px; border-bottom: 1px solid rgb(51, 51, 51); } </code></pre> <p><a href="http://jsfiddle.net/t8FBa/2/" rel="nofollow">Fiddle-DEMO</a></p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload