I've been struggling with creating a dropdown menu for some time now and I've reached a point where I need assistance. I've tried various solutions I found online, including watching tutorials on YouTube, but I can't seem to make it work correctly. Every time I implement a solution, something goes wrong, like text getting pushed down or elements shifting out of place. The last tutorial I tried can be found here: http://www.youtube.com/watch?v=_mdjwPzzKT8. The issue I'm facing now is that my submenu is not displaying at all. This is where I decided to seek help.
I am hoping that someone can assist me in fixing my code. Below is the CSS code I am currently using:
#topnav { z-index:3;
padding-top:76px; }
#topnav ul li { list-style-type:none;
display:inline;
float:right;
}
#topnav ul li a { font-family:Arial, Helvetica, sans-serif;
font-size:13px;
font-weight:bold;
text-decoration:none;
padding-left:15px;
}
#topnav ul li a:link { color:#00aeef; }
#topnav ul li a:visited { color:#00aeef; }
#topnav ul li a:active { color:#f26532; }
#topnav ul li a:hover { color:#f26532; }
#topnav ul li a:focus { color:#f26532; }
#topnav li ul { position:absolute;
left:-999em;
list-style-type:none;
}
#topnav li ul li { border-top:0px;
clear:both;}
#topnav li:hoover ul { left:auto; }
And here is the HTML code I am currently using:
<div id="topnav">
<ul>
<li><a href="contact.html">CONTACT</a></li>
<li><a href="blog.html">BLOG</a></li>
<li><a href="over ons.html">OVER ONS</a></li>
<li><a href="gedragsbeinvloeding.html">GEDRAGSBEINVLOEDING</a></li>
<li><a href="onze diensten.html">ONZE DIENSTEN</a>
<ul>
<li><a href="onderzoek.html">ONDERZOEK</a></li>
<li><a href="advies.html">ADVIES</a></li>
<li><a href="lezingen.html">LEZINGEN</a></li>
</ul>
</li>
<li><a href="index.html">HOME</a></li>
</ul>
</div>