html - X-UA-Compatible 在包含在条件注释中时不起作用?

标签 html internet-explorer meta-tags conditional-comments x-ua-compatible

我最近在条件评论中遇到了以下元标记:

<!--[if IE]><meta http-equiv="X-UA-Compatible" content="IE=edge"><![endif]-->

如果我错了请纠正我,但经过一些测试后我得出结论,这个评论似乎阻止 IE 以首选边缘模式显示文档。

有人知道为什么首先要在条件注释中放置 X-UA 元标记吗?

最佳答案

Anybody knows why

条件注释和X-UA-Compatibile都是预处理器

and is there any use of placing X-UA meta tag in a conditional comment in the first place?

没有

关于html - X-UA-Compatible 在包含在条件注释中时不起作用?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19269196/

相关文章:

html - 制作一个容器来填充内容?

javascript - 如何从 jquery datepicker 中获取选定的日期,全年日历到数组以保存到数据库

JavaScript remove() 在 IE 中不起作用

c# - Selenium WebDriver(IE 驱动程序)无法找到包含 ID 子字符串的元素

javascript - 右键启用 "open in new tab/window"

javascript - window.location.hash 始终返回前一个哈希值,而不是当前哈希值

vba - 取消选中 IE 中的复选框

javascript - 页面以 IE7 文档模式而不是 IE9 打开

image - seo如何优化一堆相似的图片?

node.js - 如何使用 React-Helmet 优化 SPA 的 SEO?