我决定在我的网站中完全放弃对 IE6 和 IE7 的支持,将其用户重定向到纯文本警告页面。但是我仍然支持 IE8 和 IE9。
我正在使用CSS3 PIE来实现这一点,并且border-radius 在两者(IE8/9)中都有效,box-shadow 在两者中都有效,但是我也依赖于线性渐变。我使用大量标签来实现这一点:
background: #E6E6E6; /* fallback */
background: -webkit-gradient(linear, 0 0, 0 bottom, from(#E6E6E6), to(#B3BCC7)); /* old webkit */
background: -webkit-linear-gradient(#E6E6E6, #B3BCC7); /* new webkit */
background: -moz-linear-gradient(#E6E6E6, #B3BCC7); /* firefox */
background: -ms-linear-gradient(#E6E6E6, #B3BCC7); /* meant to be IE... */
background: filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr='#E6E6E6', endColorstr='#B3BCC7'); /* also meant to be IE... */
background: -o-linear-gradient(#E6E6E6, #B3BCC7); /* opera */
background: linear-gradient(#E6E6E6, #B3BCC7); /* W3C standard */
-pie-background: linear-gradient(#E6E6E6, #B3BCC7); /* PIE */
behavior: url(/PIE.htc); /* load PIE.htc */
奇怪的是,线性渐变在 IE8 中有效,但在 IE9 中无效。我已经尝试了我找到的任何解决方案,但它们都没有奏效。IE8 只显示回退:背景:#E6E6E6;- 不是渐变。
我认为服务器或类似的东西没有任何问题,因为其他属性 -边界半径和框阴影- 与 PIE 一起工作,但并非没有。
我的所有属性都可以在我支持的所有浏览器中工作 - 只是不是 IE9 :(
有任何想法吗?
谢谢