Ingo Chao schrieb:


The problem with multiple classes in IE is that you have to avoid CSS multiple selectors with "common final matches" like


.explorer {background: gray; }
.mini { font-weight: normal;}
.full { font-weight: bold; }
.full.explorer {text-decoration:none; background: red;}
.mini.explorer {text-decoration:underline}

<!-- modified -->
<div class="mini explorer">Mini</div>
<div class="full explorer">Full</div>

Valid, and sometimes useful with more alternatives than shown here, but breaks IE: Now both the divs get underlining /and/ red.



MSIE/PC is reading the last class of multiple classes exclusively.

In order to use the example above, MSIE/PC is reading:

.explorer {background: gray; }
.mini { font-weight: normal;}
.full { font-weight: bold; }
.explorer {text-decoration:none; background: red;}
.explorer {text-decoration:underline}


<div class="full explorer">Full</div> <!-- font-weight:bold, background:red, text-decoration:underline -->


This circumstand we can use to show a message to MSIE/PC users only.

.standard {background: #FF0; border: 2px dotted red; padding: 5px 1em;}
.hidden.text {display: none;}
.text {display: block; color: #000;}

<div>
    <p class='This text is hidden from standard browsers'>
    Congratulations, you are using browser XY!
    </p>
</div>


regards, Uwe Kaiser <[EMAIL PROTECTED]>

______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to