I am making a website and using the dropdown, however, I can not use 2 dropdowns on a page, I can only use 1.
I have already researched and found something about using classes, but I do not know how this works or how to apply it to the code. Can anybody help me ??
UPDATED: 15:52 [16/07] So I changed the code, I managed to make the two dropdowns appear, only one underneath the other and I want them to be side-by-side. I've tried using the float (inclusive is in the code), but it's not influencing the code.
CSS:
#mainnav ul li {
margin: 0;
padding: 0;
list-style: none;
width: 230px;
}
.wrapper-menu {
float:left
position: relative;
}
.dropdown {
position: absolute;
left: 220px;
top: 300;
display: none;
}
ul li a {
display: block;
text-decoration: none;
color: #CCC;
background: #006;
padding: 5px;
border: 0px solid #ccc;
}
li:hover ul {
display: block ;
}
ul li a:hover{
text-decoration:underline;
font-weight: bold;
background: #006;
-webkit-box-shadow:0 3px 10px 0 #FFF;
text-shadow:0px 0px 5px #000;
}
#pai {
width:90%;
margin:auto;
#esquerda {
width:70%;
float:left;
}
#esquerda {
width:230px;
float:left;
}
#direita {
width:300px;
float:right;
}
#clear {
clear:both;
}
HTML:
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
<link href="../css/dropdown2(classes).css" rel="stylesheet" type="text/css" />
<style type="text/css">
{
background-color: #006;
}
</style>
<link href="../css/dropdown.css" rel="stylesheet" type="text/css" />
<style type="text/css">
body {
background-color: #006;
}
</style>
</head>
<div id="pai">
<div id="esquerda">
<nav id="mainnav">
<ul class="wrapper-menu">
<li class="wrapper-dropdown"><a href="#">TEXTO1</a>
<ul class="dropdown">
<li><a href="../Template/Conteúdo/texto2.html">texto2</a></li>
<li><a href="../Template/Conteúdo/texto3.html">texto3</a></li>
<li><a href="../Template/Conteúdo/texto4.html">texto4</a></li>
<li><a href="../Template/Conteúdo/texto5.html">texto5</a></li>
</nav>
<div id="direita" >
<nav id="mainnav" >
<ul class="wrapper-menu">
<li "wrapper-dropdown"><a href="#" >TEXTO6</a>
<ul class="dropdown">
<li><a href="../Template/Conteúdo/texto7.html">texto7</a></li>
<li><a href="../Template/Conteúdo/texto8.html">texto8</a></li>
<li><a href="../Template/Conteúdo/texto9.html">texto9</a></li>
<li><a href="../Template/Conteúdo/texto10.html">texto10</a></li>