Forum Moderators: not2easy
<ul>
<li>Test 1
<ul>
<li>Whats up</li>
<li>Hi</li>
</ul>
</li>
<li class="sel">Test 2
<ul>
<li>My name is Roger</li>
<li>Tralala</li>
</ul>
</li>
</ul>
And this:
_____________
ul li {
color: blue;
}
ul li.sel {
color: red;
}
What i need is the "My name is Roger" and "Tralala" <li's> to remain blue.
So the question is, how can i avoid herence?
I have a feeling that you don't need to beat inheritance, but you might need to use specificity to overrule a previous ruleset for the nested list?
something like...
e.g.
ul li, ul li.sel li {
color: blue;
}
ul li.sel {
color: red;
}