Yes that makes sense, and it's why I need to find out if a class exists in
the stylesheet before I apply the style.

On 3/16/07, Nathan Young -X (natyoung - Artizen at Cisco) <
[EMAIL PROTECTED]> wrote:

Hi.

> IOW given the following:
>
> <style>
> #myDiv {background: blue;}
> </style>
>
> <div id="myDiv" style="background: red">
>
> The div's background would be red, correct?


If you change background to background-color :) then yes, by the "C" in
"CSS".

Also:

<style>
#myDiv {background-color: blue;}
#myDiv {background-color: red;}
</style>

Because of declared order.

So would:

<style>
body #myDiv {background-color: red;}
#myDiv {background-color: blue;}
</style>

Because it's more specific.

<div style="background-color:red;"> will be red no matter what is in the
style block. Styles placed in the element attribute have the highest
precedence.

---->N



_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

Reply via email to