关闭IE8兼容模式,好还是坏?
希望这个问题不像我想象的那么主观。
我有一个内联网应用程序,需要与 IE8 一起使用,因为企业正在取代 IE6 作为标准浏览器。
我们的测试团队发现它在 IE8 中不起作用,但他们几乎不知道它实际上可以。他们的浏览器设置为以兼容模式运行 IE8 以支持 Intranet 应用程序。
我发现,如果我将 X-UA-Compatible 的元标记设置为 IE=EmulateIE8,我可以强制浏览器将此应用程序呈现为 IE8,并且该应用程序运行良好。
这个解决方案是否存在我不知道的陷阱?如果是这样,有更好的解决方案吗?
Hopefully this question isn't as subjective as I think it may be.
I have an Intranet application which needs to work with IE8 as the enterprise is replacing IE6 as the standard browser.
Our testing team found that it did not work in IE8, little did they know that it actually did. Their browsers were set to run IE8 in compatibility mode for Intranet applications.
I found that if I set the meta tag for X-UA-Compatible to IE=EmulateIE8 that I could force the browser to render this application as IE8 and the application worked fine.
Are there any pitfalls that I don't know about for this solution? If so, is there a better solution?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
将 X-UA-Compatible 设置为 IE=EmulateIE8 将使即将推出的 IE9 表现得像 IE8。
最初,这可能是您想要的。如果您无法在 IE9 发布时(我猜是明年的某个时候)对其进行全面测试,那么组织立即升级到 IE9 可能会有所帮助。
当您完全测试了所有内容并希望应用程序在 IE9 的本机模式下工作时,您会有点卡住。您可以将 X-UA-Compatible 设置为 IE=IE9,IE9 可以正常工作,但这对 IE8 意味着什么?
但这都是猜测。现在,它不会伤害任何东西。如果您需要进行更改以处理更高版本的 IE9,您可以稍后进行。
Setting X-UA-Compatible to IE=EmulateIE8 will make the upcoming IE9 behave like IE8.
Initially, this may be what you want. If you're not in a position to fully test against IE9 when it comes out (sometime next year, I presume), it may help should the organization upgrade to IE9 immediately.
When you've fully tested everything, and want the application to work in IE9's native mode, you'll be a little bit stuck. You could set X-UA-Compatible to IE=IE9, and IE9 will work fine, but what does that mean to IE8?
That's all speculative though. Right now, it won't harm anything. If you need to make changes to handle later versions of IE9, you can do that later.