【问题标题】:Does this conditional css loading for IE7 and lower work for IE8 in compability mode?IE7 的这种有条件的 css 加载是否适用于兼容模式下的 IE8?
【发布时间】:2011-06-13 04:35:14
【问题描述】:

IE7 和更低版本的这种有条件的 css 加载是否适用于兼容模式下的 IE8?

<!--[if lt IE 8]>
        <link rel="stylesheet" type="text/css" href="ie7-and-down.css" />
<![endif]-->

【问题讨论】:

  • 只有一种方法可以找出答案,对吧?

标签: css internet-explorer internet-explorer-8 internet-explorer-7 conditional


【解决方案1】:

http://blogs.msdn.com/b/ie/archive/2008/08/27/introducing-compatibility-view.aspx -> 这清楚地表明兼容性视图是强制 IE8 像 IE-7 一样呈现页面。

如果您安装了 IE 开发工具栏 (Install and use IE developer toolbar),您可以检查渲染时是否使用了 CSS,或者在兼容模式下运行脚本 @Detect Browser 以检查您正在点击哪个浏览器。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2011-03-09
    • 2011-08-27
    • 1970-01-01
    • 2011-07-27
    • 2023-03-23
    • 2010-11-04
    相关资源
    最近更新 更多