'!important' rules

Does a rule with '!important' overrule an inline style?

Say I have this in my stylesheet:

li {
height: 20px !important;
}

And in the XHTML:

<li style="height: 22px">Item</li>

Will the height be 22px or 20px (forget about borders and padding)?

The problem is I was creating image tab rollovers. I replaced the images with Javascript, and used CSS to create rollovers. The odd thing is Mozilla and Opera only made the tabs 20px high and hdie the overflow was to give both declarations '!important'. IE doesn't understand !important, so I tried inline styles. Still didn't work.

Why can't all browsers be as great as Opera 7? Lol.
Thanks,
Dante

Received on Saturday, 15 May 2004 20:49:56 UTC