哪个X-UA兼容优先? Http-header或Meta-tags? [英] Which X-UA-Compatible takes precedence? Http-header or Meta-tags?
本文介绍了哪个X-UA兼容优先? Http-header或Meta-tags?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
正如问题所述。如果您的HTTP标头和文档上的元标记都有X-UA兼容,并且它们会发生冲突,哪一个受到IE的尊重?
As the question states basically. If you have X-UA-Compatible in both your HTTP headers and a meta tag on your document, and they conflict, which one gets respected by IE?
推荐答案
TL; DR:元标记获胜
我找到了以下(更新)流程图 这里 (链接已断开)并关联博文提供IE9如何确定文档模式的说明:
I found the following (updated) flowchart here (link is broken) and associated blog post that provides an explanation of how IE9 determines document mode:
这篇关于哪个X-UA兼容优先? Http-header或Meta-tags?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文