This is my markup:
<div id="nav">
<ul>
<li><a href="#">Page 1</a></li>
<li><a href="#">Page 2</a></li>
<li>
<a href="#">Articles</a>
<ul class="inside-ul">
<li><a href="#">Article 1</a></li>
<li><a href="#">Article 2</a></li>
<li><a href="#">Article 3</a></li>
</ul>
</li>
<li><a href="#">Page 3</a></li>
</ul>
</div>
I apply styling to the parent <ul>
like this:
#nav ul {
something;
}
#nav ul li {
something;
}
#nav ul li a {
something;
}
And I apply styling to the child <ul>
like this:
.inside-ul {
something;
}
.inside-ul li {
something;
}
.inside-ul li a {
something;
}
But the problem is, the child <ul>
(.inside-ul) doesn't change at all, it's like it inherits everything from its parent. I have tried using !important
in my CSS file but it still remains the same.
Here is an image of what's happening:
http://i47.tinypic.com/w1brkw.jpg
I hope I've explained myself clearly, thanks.