Exclamation Hack

Test of Filter

This text will be green if the rule has been applied.

Code Syntax

! #testElement {
   color: #00cc00;

Browser Support / Behaviour

Applied By

Not Applied By


Special Notes / Browser Specific Behaviour

Combine this with one of Edwardson Tan's comment bugs and you have yourself a Safari 1.x / OmniWeb4.5 specific hack.

An exclamation mark is an invalid character in a selector so any associated rules should be ignored by standards-compliant browsers (so the text in the example block should be red in compliant browsers).

More information