an ordinary blog — andr3.net

rss feed

my lifestream rss feed

are you tired of this? then return to latest posts

IE7 drops root node selector hack

Justin Rogers announced on the IEBlog that IE7 will not support the known * html hack while running on strict mode. All the IE-only Rules you include in your CSSes using this hack won't work on IE7.

Don't panic!

If this was an isolated decision, this could break many many pages around the web, but with all the fixes they're doing on the rendering engine, all the rules you were adding just for IE, will probably be pointless in IE7.

This makes sense, as Justin pointed out, because if you have IE7 recognizing CSS2.1 selectors and also recognizing this hack, the result would be elements being affected by both rules and this could lead to incorrect styling of those elements. So, dropping the hack ensures IE7 will apply the rules according to the CSS 2.1 standard, and not the IE-only rules.

They've already announced they're fixing lots of know bugs, and now, they also announce the improved support of:


  • multi-class selectors
    (p.red.yellow)
  • better Pseudo-element parsing
    (p:first-letter{ color: blue; } should be valid).


So, as you can see, the Microsoft + WaSP joint task force is producing some – pleasant – results. Another good result is that ASP.net 2.0 will generate valid XHTML 1.0 code.

If you still feel the need to use this hack, you can make it work on IE7 by making IE enter quirks mode, because it was only removed in strict rendering mode. You will loose all the fixes they're doing to the strict mode, though.

These could be catastrophic news, but seeing their effort in fixing the CSS bugs in their rendering engine and bringing as much support of CSS 2.1 as possible, i don't expect it to be catastrophic. This could be yet another step towards a world in which you don't have to include browser-specific hacks to display your website correctly in every browser. :)

Comments

↑ top