你的网站添加X-UA-Compatible meta标签了吗?
???? <meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
???? <meta http-equiv="Content-Language" content="gb2312" />
???? <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
???? <meta name="robots" content="all" />
???? <meta name="googlebot" content="all" />
???? <meta name="description" content="提供最新的asp源碼,php源碼,.net源碼,flash源碼,網站源碼,網頁源碼,模板,軟件下載" />
???? <meta name="keywords" content="asp源碼,php源碼,.net源碼,flash源碼,網站源碼,網頁源碼,模板,軟件" />
???? <title>源碼下載網 - 提供最新免費網站源碼下載</title>
???? <META name="copyright" content="www.downhtml.com" />
??????? 那這個標簽是什么意思呢?讓我來看下msdn上的說明:
??????? In IE8 Beta 1, that option is the “IE=7” X-UA-Compatible tag, which instructs IE8 to display content in IE7 Standards mode. However, the scenario this doesn’t address is when IE=7 is applied as an HTTP header to a site that contains Quirks mode pages. The IE=7 HTTP header will force all pages – both Quirks and Standards – to display in IE7 Standards mode. Developers using this header while updating their sites would then have to add the “IE=5” <META> tag to each page they want to keep in Quirks mode. This logic is fine for many websites. However, if a site has lots of Quirks mode pages, or for the case where pages with frames host a mix of Strict and Quirks mode content – as brought to light by IE8 Beta 1 user feedback – the compatibility opt-out adds a bit more work than we intended.
???? X-UA-Compatible是針對ie8新加的一個設置,對于ie8之外的瀏覽器是不識別的,這個區別與content="IE=7"在無論頁面是否包含<!DOCTYPE>指令,都像是使用了 Windows Internet Explorer 7的標準模式。而content="IE=EmulateIE7"模式遵循<!DOCTYPE>指令。對于多數網站來說,它是首選的兼容性模式。
????? 目前IE8尚在測試版中,所以為了避免制作出的頁面在IE8下面出現錯誤,建議直接將IE8使用IE7進行渲染。也就是直接在頁面的header的meta標簽中加入如下代碼:
<meta http-equiv="X-UA-Compatible" content="IE=7" />
這樣我們才能使得頁面在IE8里面表現正常! http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />標簽!
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<meta http-equiv="Content-Language" content="gb2312" />
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
<meta name="robots" content="all" />
<meta name="googlebot" content="all" />
<meta name="description" content="提供最新的asp源碼,php源碼,.net源碼,flash源碼,網站源碼,網頁源碼,模板,軟件下載" />
<meta name="keywords" content="asp源碼,php源碼,.net源碼,flash源碼,網站源碼,網頁源碼,模板,軟件" />
<title>源碼下載網 - 提供最新免費網站源碼下載</title>
<META name="copyright" content="Downhtml.com" />
那這個標簽是什么意思呢?讓我來看下msdn上的說明:
In IE8 Beta 1, that option is the “IE=7” X-UA-Compatible tag, which instructs IE8 to display content in IE7 Standards mode. However, the scenario this doesn’t address is when IE=7 is applied as an HTTP header to a site that contains Quirks mode pages. The IE=7 HTTP header will force all pages – both Quirks and Standards – to display in IE7 Standards mode. Developers using this header while updating their sites would then have to add the “IE=5” tag to each page they want to keep in Quirks mode. This logic is fine for many websites. However, if a site has lots of Quirks mode pages, or for the case where pages with frames host a mix of Strict and Quirks mode content – as brought to light by IE8 Beta 1 user feedback – the compatibility opt-out adds a bit more work than we intended.
X-UA-Compatible是針對ie8新加的一個設置,對于ie8之外的瀏覽器是不識別的,這個區別與content="IE=7"在無論頁面是否包含指令,都像是使用了 Windows Internet Explorer 7的標準模式。而content="IE=EmulateIE7"模式遵循指令。對于多數網站來說,它是首選的兼容性模式。
目前IE8尚在測試版中,所以為了避免制作出的頁面在IE8下面出現錯誤,建議直接將IE8使用IE7進行渲染。也就是直接在頁面的header的meta標簽中加入如下代碼:
???????? <meta http-equiv="X-UA-Compatible" content="IE=7" />
這樣我們才能使得頁面在IE8里面表現正常! http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />標簽!
????? 文章來源 源碼下載網 ww.downhtml.com 轉載請注明出處。
總結
以上是生活随笔為你收集整理的你的网站添加X-UA-Compatible meta标签了吗?的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: ora-12514: tns: 监听程序
- 下一篇: 使用Silverlight3中的Data