Previous Message
Next Message

Text Decoration Problem

Sent by Philippe Wittenbergh on 26 July 2005 05:05

On 26 Jul 2005, at 6:28 am, Scott Taylor wrote:

> #right_nav ul li {
>    text-decoration: underline;
> }
> #right_nav ul li ul li {
>    text-decoration: none;
> }
> In Firefox, all li elements, including the second ordered list, become 
> underlined.  In IE 6., only the first ordered list elements become 
> underlined (as I would like them to be).
> How can I fix this?  What am I doing wrong?
> Here is the HTML: 

The second level list-items are still wrapped within the parent li. The 
text-decoration you see in good browsers like Opera, Firefox, Safari 
and IE Mac is the text-decoration applied to the top level <li>.

very much simplified, you have this
<div> some text <span> some other text</span> and yet some more 
div {text-decoration:underline; color black}
span {text-decoration:none; color:red;}
The span will still have a black coloured text-decoration.

You gonna have to wrap the text-node of the toplevel <li> in a span, 
and style that.

Philippe Wittenbergh

css-discuss [EMAIL-REMOVED]]
List wiki/FAQ --
Supported by --
Previous Message
Next Message

Message thread:

Possibly related: