Problem description: Copy code The code is as follows: <meta http-equiv="X-UA-Compatible" content="IE=9; IE=8; IE=7; IE=EDGE" /> 1. What does this mean? 2. Some examples use "," to separate IE versions, while some use ";", which one is correct? 3. I want to know the meaning of the order IE=9; IE=8; IE=7; IE=EDGE. In the document, <!DOCTYPE> reply: For IE8 and above, for example: Copy code The code is as follows: <meta http-equiv="X-UA-Compatible" content="IE=9; IE=8; IE=7" /> Force the browser to render according to a specific version of the standard. But IE7 and below are not supported. If separated by a semicolon (;), different browser versions will have different compatibility, for example Copy code The code is as follows: <meta http-equiv="X-UA-Compatible" content="IE=7; IE=9" /> The above shows that IE8 and IE7 are rendered according to IE7 standards, but IE9 is still rendered according to IE9 standards. This allows for different levels of backward compatibility. In reality though, you only need to choose one version: Copy code The code is as follows: <meta http-equiv="X-UA-Compatible" content="IE=8" /> This will be easier for testing and maintenance. A more useful approach is usually to perform simulation Copy code The code is as follows: <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8" /> For IE=EDGE Copy code The code is as follows: <meta http-equiv="X-UA-Compatible" content="IE=Edge" /> This means that the browser will be forced to render according to the latest standards. Just like using the latest version of jQuery from Google's CDN, this is up to date, but may also break your layouts without a fixed version. Finally, consider this Copy code The code is as follows: <meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1" /> Adding "chrome=1" will allow the site to render on clients that use Chrome Frame, but will have no effect on clients that don't. Copy code The code is as follows:For more information, there is plenty to read here, and if you want to learn about ChromeFrame (which I recommend) you can learn about its implementation here. PS: X-UA-Compatible is a special file header tag for IE8 version, which is used to specify different page rendering modes for IE8. It is not recognized by browsers other than IE8. Currently, most websites use <meta http-equiv=”X-UA-Compatible” content=”IE=EmulateIE7″ > as a compatibility method for IE8. In order to avoid errors in the produced pages under IE8, it is recommended to directly render IE8 using IE7. That is, add the following code directly to the meta tag of the page header: Copy code The code is as follows:<meta http-equiv=”X-UA-Compatible” content=”IE=7″ /></p> <p><meta http-equiv=”X-UA-Compatible” content=”IE=EmulateIE7″ ></p> <p><meta http-equiv=”X-UA-Compatible” content=”IE=EmulateIE8″ > But <meta http-equiv=”X-UA-Compatible” content=”IE=EmulateIE7″ > is still the preferred choice. StackOverFlow original link; http://stackoverflow.com/questions/14611264/x-ua-compatible-content-ie-9-ie-8-ie-7-ie-edge?answertab=active#tab-top |
<<: Solution to Incorrect string value in MySQL
>>: Teach you how to use Portainer to manage multiple Docker container environments
In the past, float was often used for layout, but...
Monday to Sunday time format conversion (Y --- ye...
This article example shares the specific code of ...
It’s great to use CSS to realize various graphics...
privot is the intermediate table of many-to-many ...
As a required course for front-end developers, CS...
1. Spread Operator The spread operator is three d...
Some special characters and icons used in the pro...
This article example shares the specific code of ...
1. Import mysql command The mysql command import ...
I am going to review Java these two days, so I wr...
Angular Cookie read and write operations, the cod...
When using Maven to manage projects, how to uploa...
Table of contents 1. router-view 2. router-link 3...
Table of contents 1. Object properties 1.1 Attrib...