Note that there are some explanatory texts on larger screens.

plurals
  1. POIssue to create a horizontal navigation menu (nokia-like)
    primarykey
    data
    text
    <p>I'm trying to make a Nokia-like horizontal menu (like <a href="http://www.nokia.com/fr-fr/accessoires/accessoire/md-50w/" rel="nofollow noreferrer">here</a>) but without success. As you can see on my <a href="http://jsfiddle.net/vAA7g/" rel="nofollow noreferrer">JSFiddle</a> I can't get the white background of the active menu item to take the full height of the blue menu-container minus 1 px at the top. How could I achieve that? Many thanks</p> <p><img src="https://i.stack.imgur.com/VImK6.png" alt="enter image description here"></p> <p>HTML:</p> <pre><code>&lt;div id="menu-container"&gt; &lt;div id="menu"&gt; &lt;ul&gt; &lt;li&gt;Category 1&lt;/li&gt; &lt;li class="active"&gt;Category 2&lt;/li&gt; &lt;li&gt; &lt;a title="" href=""&gt;Category 3&lt;/a&gt; &lt;/li&gt; &lt;li&gt;Category 4&lt;/li&gt; &lt;li&gt;Category 5&lt;/li&gt; &lt;/ul&gt; &lt;/div&gt; &lt;!-- End DIV Menu --&gt; &lt;/div&gt; </code></pre> <p>CSS:</p> <pre><code>#menu-container { display: table; width: 100%; background: #124191; height: 50px; padding-left: 20px; color: #fff; } #menu { vertical-align: middle; display: table-cell; } #menu ul { float: left; list-style: none; } #menu ul li { display: inline-block; width: 130px; line-height: 18px; text-align: center; color: #124191; font-weight: 400; font-size: 12px; background: #fff; } #menu ul li a { text-decoration: none; font-weight: 400; font-size: 12px; /* This is the sub-menu items */ display: block; } #menu ul li a:active { background: fff; } </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

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