如何将 IE9 中的页面呈现为 IE8?
我正在尝试将 IE9 中的页面渲染为 IE8,因为我在 IE9 中看到一些奇怪的渲染,我目前不确定如何解决。我正在使用这个元标记:
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8">
但我仍然在 IE9 中看到渲染问题,而在 IE8 中则没有看到。您应该能够在此处页面上看到 IE9 中的问题。插件生成的圆角块无法正确渲染。
我想知道是否有人对我还可以尝试什么有任何建议?
I am trying to render a page in IE9 as IE8, as I am seeing some strange rendering in IE9 which I am not sure how to sort out at the moment. I am using this meta tag:
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8">
But I am still seeing the rendering issue in IE9, which I don't see in IE8. You should be able to see the issue in IE9 on this page here. The rounded corner blocks generated by a plugin aren't rendering properly.
I am wondering if anyone has any suggestions as to what else I can try?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果您想要 IE 版本的确切行为,那么使用该版本是无可替代的。像 IETester 这样的工具可以让您并行安装和运行多个版本,或者更准确(但不太方便)的方法是使用具有针对不同版本 IE 的映像的虚拟机。
您也可以尝试查看插件本身。也许它使用浏览器嗅探或 IE 条件注释来检测 IE 版本。
但作为一般规则,如果您必须诉诸 X-UA-Compatible,您可能做错了什么。对于讨厌的浏览器来说,这是一个讨厌的黑客行为,从长远来看,你最好围绕它进行设计(或者将圆角的东西留给原生支持它的浏览器)。
If you want the exact behaviour of an IE version there is no substitute to using that version. Tools like IETester will let you install and run several versions side-by-side or an even more accurate (but less convenient) method is to use a virtual machine with an image for different versions of IE.
You could also try looking at the plugin itself. Perhaps it's using browser sniffing or IE conditional comments to detect the IE version.
As a general rule though if you have to resort to X-UA-Compatible you're probably doing something wrong. It's a nasty hack for a nasty browser and in the long run you would be better off designing around it (or leave the rounded corners stuff to the browsers that support it natively).