一些CSS hack已经失去作用
根据IEblog的消息,IE7中这些CSS hack将不再适用,记一下:
Call to action: Please check your pages
Here is a list of common CSS hacks to look out for (please also consider their variations):
- html > body http://css-discuss.incutio.com/?page=ChildHack
- * html http://css-discuss.incutio.com/?page=StarHtmlHack
- head:first-child + body http://centricle.com/ref/css/filters/tests/owen/
- head + body http://www.dithered.com/css_filters/css_only/head_adjacent_sibling_body.html
- body > element http://css-discuss.incutio.com/?page=ChildHack
We ask that you please update your pages to not use these CSS hacks. If you want to target IE or bypass IE, you can use conditional comments .
以后可以用条件注释来写针对低版本IE的hack,也就是上面提到的 conditional comments,比如这样:
<!--[if lt IE 7]>
<link rel="stylesheet" href="ie.css" type="text/css" />
<![endif]-->


