I have a nested list I'm trying to style with CSS, but am having a problem...
The inner-most li styles are being overridden by the main li styles. Here's my CSS code:
#navigation #block-nice_menus-1 ul li { float: left; line-height: 2em; padding: 0 1.5em 0 0; }
#block-nice_menus-1 ul li ul li { float: none; font-weight: normal; line-height: 2.5em; padding: 0; }
ALL my li's are floated left, even though I want the inner-most ones not to be floated at all.
Anyone know why this is happening and how I can fix it? (I'd prefer not to have to use the '!important' rule...)
Nevermind, as soon as I posted the topic, I saw the code and realised that there's a '#navigation' on the first style that shouldn't be there. With that removed everything works as expected :)
I have a nested list I'm trying to style with CSS, but am having a problem...
The inner-most li styles are being overridden by the main li styles. Here's my CSS code:
#navigation #block-nice_menus-1 ul li {
float: left;
line-height: 2em;
padding: 0 1.5em 0 0;
}
#block-nice_menus-1 ul li ul li {
float: none;
font-weight: normal;
line-height: 2.5em;
padding: 0;
}
ALL my li's are floated left, even though I want the inner-most ones not to be floated at all.
Anyone know why this is happening and how I can fix it? (I'd prefer not to have to use the '!important' rule...)