Dermot Ward wrote:
> Hi Bobby,
>
> Thank you very much for your help.
>
> Please excuse my typo where I inadvertantly put 'class' instead of 'one'.
>
> Your solution below solves the main problem, it stops the bold style
> being applied to the nested list in IE7.
>
> <ul>
>
> <li class="one">One</li>
> <li>
> <ul>
> <li class="two">One A</li>
> <li class="two">One B</li>
> <li class="two">One C</li>
> </ul>
> </li>
> </ul>
>
> However IE7 now inserts a gap between the first li and the second ul.
>
>
>
> * One
> *
> o One A
> o One B
> o One C
>
> I'll play around with this later this evening.
> And thanks for the info on ul and child elements.
>
Yes and that is totally correct. The right way to nest this is the
following:
<ul>
<li class="one">One
<ul>
<li class="two">One A</li>
<li class="two">One B</li>
<li class="two">One C</li>
</ul>
</li>
</ul>
The other solution doesn't make the UL a child of "One". You also don't
need classes on every list item but use descendant selectors instead:
<ul class="one">
<li>One
<ul>
<li>One A</li>
<li>One B</li>
<li>One C</li>
</ul>
</li>
</ul>
ul.one li{
font-weight:bold;
color:#0c0;
}
ul.one li li {
font-weight:normal;
color:#000;
}
______________________________________________________________________
css-discuss [[email protected]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/