前言

IE 8 及以下版本的速度较慢。 特别是前端的js 和 css 内容较多时尤为突出。

就笔者的开发经验来说GWT, Ext JS, raphael , draw2d 等开发的系统在IE下使用是相当的吃力。

特别是IE 的VML 看起来比SVG的效率要差多了。 IE 9 及以上倒是声明已经可以使用svg.

但是就目前的状况来说, IE 7 和IE 8 还是有一定的占有量的,

如何让IE 7 和IE 8 的速度快起来。 google 有开发一个IE的插件Google Chrome Frame。

不过不好的是,google在2014 之后就不再support 这个项目了。 因为google 认为到那个时候大家用的应该都是最新的浏览器, 再花钱维护这个项目也就没什么意义了。

 

 

页面开发

安装完成之后, 页面并不会自动生效, 需要在相应的html 加入以下标识

 

<meta http-equiv="X-UA-Compatible" content="chrome=1">


 

 

如果嫌每个页面都添加麻烦的话,也可以加到配置文件中:

1. apache 服务器, httpd.conf文件中加入

 

<IfModule mod_setenvif.c>
<IfModule mod_headers.c>
BrowserMatch chromeframe gcf
Header append X-UA-Compatible "chrome=1" env=gcf
</IfModule>
</IfModule>


 

2. IIS 服务器,web.config文件中加入

 

<configuration>
<system.webServer>
<httpProtocol>
<customHeaders>
<add name="X-UA-Compatible" value="chrome=1" />
</customHeaders>
</httpProtocol>
</system.webServer>
</configuration>





chrome=1   - Always active


chrome=IE7 - Active for IE major version 7 or lower


chrome=IE8 - Active for IE major version 8 or lower