IE8 模拟IE7 行为设置(转贴)
2010-03-30 10:43
260 查看
工作原因,接触了下IE8,主要是研究IE8在模拟IE7行为上的差别, 在这推荐下面的blog还有msdn的相关信息
http://blogs.msdn.com/ie/archive/2008/06/10/introducing-ie-emulateie7.aspx http://msdn.microsoft.com/en-us/library/cc288325(VS.85).aspx
总结来说,可以有3种方式,让IE8来模拟IE7的行为:
1) IE8 Compatibility View Setting 模式:勾选 “Display all website in Compatibility View” (IE8提供了3种方式,可以根据需要选择适合的)
我在这选择的是所有访问的site都将模拟IE7的模式
2) 在server端的web.config种, 添加一个 custom HTTP header:<add name="X-UA-Compatible" value="IE=EmulateIE7" />
Implementing the HTTP header is beneficial if a site owner wants most of their site to render as it did in IE7 or if there are no plans to update site content. Inclusion of this header honors any Quirks mode pages that belong to the site.
当server上大多数site需要此操作时,可以使用这个设置。
3) 在client端添加一个特殊的 HTML tag ,在需要的page上: 添加<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /> 在 <head> 标签里面
Using the meta-tag on a per-page basis is beneficial when the publisher wants to operate in specific pages to render as they did in IE7.
此设置是相对特别页面有效的。
原帖地址:http://joeytravel.blog.sohu.com/116239542.html
http://blogs.msdn.com/ie/archive/2008/06/10/introducing-ie-emulateie7.aspx http://msdn.microsoft.com/en-us/library/cc288325(VS.85).aspx
总结来说,可以有3种方式,让IE8来模拟IE7的行为:
1) IE8 Compatibility View Setting 模式:勾选 “Display all website in Compatibility View” (IE8提供了3种方式,可以根据需要选择适合的)
我在这选择的是所有访问的site都将模拟IE7的模式
2) 在server端的web.config种, 添加一个 custom HTTP header:<add name="X-UA-Compatible" value="IE=EmulateIE7" />
Implementing the HTTP header is beneficial if a site owner wants most of their site to render as it did in IE7 or if there are no plans to update site content. Inclusion of this header honors any Quirks mode pages that belong to the site.
当server上大多数site需要此操作时,可以使用这个设置。
3) 在client端添加一个特殊的 HTML tag ,在需要的page上: 添加<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /> 在 <head> 标签里面
Using the meta-tag on a per-page basis is beneficial when the publisher wants to operate in specific pages to render as they did in IE7.
此设置是相对特别页面有效的。
原帖地址:http://joeytravel.blog.sohu.com/116239542.html
相关文章推荐
- IE8 模拟IE7 行为设置 分享
- 强制将IE8 IE9设置为IE7兼容模式来解析
- 更改IE7、IE8的设置访问Terminal Service
- css设置ie7,ie8中div高度自动设置
- 强制将IE8设置为IE7兼容模式来解析网页(转)
- [转]CSS中设置div最小高度(支持IE6, IE7, IE8, FF等浏览器)
- 强制将IE8设置为IE7兼容模式来解析网页
- IE8中模拟IE7按钮(Emulate IE7 button)的秘密
- 设置IE8使用IE7的样式的代码
- 强制将IE8设置为IE7兼容模式来解析网页【转】
- 强制将IE8设置为IE7兼容模式来解析网页
- 三张照片解决--win10系统的edge浏览器设置为浏览器IE8,IE7,IE9---完美解决 费元星
- ie6、ie7及ie8创建iframe时设置name问题
- 强制将IE8设置为IE7兼容模式来解析网页
- DIV+CSS相对IE6 IE7和IE8浏览器行为区别及兼容性问题整理
- 强制将IE8设置为IE7兼容模式来解析网页
- ie7 ie8 使用border模拟圆
- 在IE8下设置兼容IE7或以下版本
- 强制将IE8设置为IE7兼容模式来解析网页
- 强制将IE8设置为IE7兼容模式来解析网页