本文介绍了如何设置X-UA-Compatible标头为IE = EmulateIE7使用Apache 2.0的IE浏览器8?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我能够设置这个头文件
X-UA-Compatible "IE=EmulateIE7"
使用的
下面的指令在我的Apache 2.0 httpd.conf文件:
using the following directive in my Apache 2.0 httpd.conf file:
<Location /mypath>
Header set X-UA-Compatible "IE=EmulateIE7"
</Location>
我如何配置Apache只设置这个头为IE 8浏览器?
How can I configure Apache to only set this header for IE 8 browsers?
推荐答案
这是我能想出迄今最好的。它的看起来的工作。如果任何人有一个更好的办法,请让我知道。
This is the best I could come up with so far. It seems to work. If anyone has a better way, please let me know.
BrowserMatch "^.*MSIE 8.*$" emulate_ie7
<Location /mypath>
Header set X-UA-Compatible "IE=EmulateIE7" env=emulate_ie7
</Location>
这篇关于如何设置X-UA-Compatible标头为IE = EmulateIE7使用Apache 2.0的IE浏览器8?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!