jeudi 19 juin 2014

I am trying to change color of some elements hovering using css but code doesn't work propertly


Vote count:

0




Sorry if this is stupid question but i really can't find solution of my problem.

I want to change color of li ul li but i don't know what i'am doing wrong.

Here is my code

HTML



<ul class="s">
<li>
<ul>#1
<li>Hello</li>
<li>Hello</li>
</ul>
<ul>#2
<li>Hello</li>
<li>Hello</li>
</ul>
</li>
</ul>


CSS



.s li ul li{
color:red;
list-style:none;

}
.s li {
list-style:none;
}
.s li ul{
color:green;
}
.s li ul:hover .s li ul li{
color:black;
}


U can also find my fiddle here



asked 2 mins ago






Aucun commentaire:

Enregistrer un commentaire