An Exotic CSS Hack for Internet Explorer

HTML5, CSS3 and JavaScript

The Fine Art of Web Development by Martin Ivanov

Here is a less known and rather exotic CSS hack, visible for Internet Explorer based on a rendering bug. Unfortunately, it is visible both in versions 6 and 7, but still it can be useful as a last resort for styling.

And here it comes:

 color: green;
.color: red;

Internet Explorer 6 and 7 will render <h1>...</h1> in red, while all other browsers will disregard the dot-prefixed property.

Categories and Tags

© 2006 - 2023 Martin Ivanov