I have a asp.net-application. Now, my asp.net-Page will always be loaded in CompatiblityView in IE10. How can I prevent this, that IE10 will use CompatiblityView for my page?
I have already added <meta http-equiv="X-UA-Compatible" content="IE=10" /> but Internet Explorer is still use Compatiblity-Mode instead of normal IE10-Mode.
When I open other websites, they are loaded in normal IE10-Mode.
When I load for example http://www.google.ch it will use normal IE10-Mode:
When I load my page, IE will change to compatiblity-Mode:
I can I prevent IE10 changing to Compatiblity-Mode?
Related
In our application we are using <meta http-equiv="X-UA-Compatible" content="IE=Edge" /> as the first line of code inside <head>tag. In Local and QA it is working fine, but when we try to open PROD in IE we are facing some problem - it is opening in document mode 7. In IE EDGE it is working fine, we are facing this issue in IE 11.
What might be the problem?
If:
The production environment is in the Intranet zone (right-click and then choose Properties), and
The page does not contain a <!DOCTYPE> directive, and
The Default settings have not been changed
(Other factors may also be involved.)
Then, the page is likely loading in IE7 Compatibility mode by design.
If you cannot change the page to include the HTML5 doctype directive (<!DOCTYPE html>), then you might see if the web server can serve the x-ua-compatible header with the page.
This question already has answers here:
What does <meta http-equiv="X-UA-Compatible" content="IE=edge"> do?
(12 answers)
Closed 8 years ago.
What will this following tag will do to my browser when a HTML page is loaded?
<meta http-equiv="X-UA-Compatible" content="IE=edge">
http://msdn.microsoft.com/en-us/library/jj676915(v=vs.85).aspx
Understanding legacy document modes
Use the following value to display the webpage in edge mode, which is
the highest standards mode supported by Internet Explorer, from
Internet Explorer 6 through IE11.
<meta http-equiv="x-ua-compatible" content="IE=edge">
Note that this is functionally equivalent to using
the HTML5 doctype. It places Internet Explorer into the highest
supported document mode. Edge most is most useful for regularly
maintained websites that are routinely tested for interoperability
between multiple browsers, including Internet Explorer.
Note Starting with IE11, edge mode is considered the preferred document mode. (In
earlier versions, it was considered experimental.) To learn more, see
Document modes are deprecated. Starting with Windows Internet Explorer
8, some web developers used the edge mode meta element to hide the
Compatibility View button on the address bar. As of IE11, this is no
longer necessary as the button has been removed from the address bar.
Because it forces all pages to be opened in standards mode, regardless
of the version of Internet Explorer, you might be tempted to use edge
mode for all pages viewed with Internet Explorer. Don't do this, as
the X-UA-Compatible header is only supported starting with Internet
Explorer 8.
Tip If you want all supported versions of Internet
Explorer to open your pages in standards mode, use the HTML5 document
type declaration, as shown in the earlier example.
We've run into an unusual bug with Internet Explorer and we need to force IE 11 to behave as IE 10 (since this bug is not present in IE 10).
I have tried the following:
<meta http-equiv="x-ua-compatible" content="IE=10">
but unfortunately this does not work and I have not found anything relevant or helpful from Google searches or the docs. So how do we get IE 11 to behave as IE 10?
Do the following:
The correct meta string is:
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE10"/> (I added it just below the <title>. Preserve case, IE crappy code might be also case sensitive.)
And a valid <!DOCTYPE... must be present at the very 1st line of your page (no space or lines before it)
You can verify if it works by hitting F12 to show the IE11 developer tools. On the left side there is a grey bar, scroll it down and select Emulation, if it shows Document mode: IE10 it will be fine!
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE10">
Should work.
I know this will not set IE11 to IE10 mode but it might me worth a shot to try the edge setting.
<meta http-equiv="X-UA-Compatible" content="IE=edge">
This flow chart shows how the document mode works. The image is from the Microsoft MSDN site. http://msdn.microsoft.com/en-us/library/ff955275%28v=vs.85%29.aspx
Another useful link MSDN IE document modes http://msdn.microsoft.com/en-us/library/ff406036(v=vs.85).aspx
I just had the same problem. Its as if the x-ua-compatible tag does not change the document mode unless its the first meta tag in the header. I had a script tag above it.
If you put the meta tag you tried as the first tag in the header and press F12, you will see the document mode stays on 10.
This may help you to set response header with IIS: http://msdn.microsoft.com/en-us/library/ff955275(v=vs.85).aspx
I also tried this, it doesn't works for me
<meta http-equiv="x-ua-compatible" content="IE=10">
also its works well if i manually change Useragentstring in F12 IE console to IE10,
I got a solution here below and its works for me, now my pages works properly in IE11 without changing anything in my code
Refer this
https://stackoverflow.com/a/20422240/2089963
Setting in we.config:
<system.webServer>
<httpProtocol>
<customHeaders>
<clear/>
<add name="X-UA-Compatible" value="IE=EmulateIE9"/>
</customHeaders>
</httpProtocol>
When I view my website in IE10, it seems that it's automatically forcing IE8 document standards. However, I would like it to use IE9 standards, when being viewed in IE10.
Is there a way to do this?
The page has <!DOCTYPE html> at the top.
EDIT: It turned out that I had <meta http-equiv="X-UA-Compatible" content="IE=8" /> in the page header, which was causing the page to render in IE8 document mode. Changing this to IE=9 fixed the issue.
I recommend to use the X-UA meta tag. The X-UA-Compatible meta tag allows you to choose what version of Internet Explorer the page should be rendered as.
You specify the user agent and version to use in the contents of the tag. The current options you have for the content are: IE=5, IE=EmulateIE7, IE=7, IE=EmulateIE8, IE=8, IE=EmulateIE9, IE=9, IE=edge.
Emulating the version tells the browser to use the DOCTYPE to determine how to render content. Pages without a DOCTYPE will be rendered in quirks mode. If you tell it to use the browser version without emulating (i.e. IE=7) the browser will render the page in standards mode whether or not there is a DOCTYPE declaration. IE=edge tells Internet Explorer to use the highest mode available to that version of IE. Internet Explorer 8 can support up to IE8 modes, IE9 can support IE9 modes and so on.
I think you need this:
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
Use X-UA meta tag:
<meta http-equiv="X-UA-Compatible" content="IE=9" />
And I don't know why you want to do this, as IE 10 is far more excellent than any of the previous versions of IE, if you are testing, you can press F12 and change the mode
On one of my sites, IE 8 is displaying the compatibility view button despite the presence of the X-UA-Compatible header. In IE 9, adding this header removes the button and sets the correct rendering mode, but why doesn't it do the same under IE 8? If the user clicks the button in IE8, the site rendering breaks on several pages so how can I remove this button to stop them clicking it?
The site in question is www.venuefinder.com
your page is including the following meta tag:
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE9" />
Thus IE9 hides the button and IE8 doesn't understand it (since IE9 didn't exist when IE8 was shipping)
To ensure both IE8 and IE9 (and IE10) don't show the button you'd likely want to adjust your page to include a modern DOCTYPE
<!doctype html>
and set the meta tag to edge
<meta http-equiv="X-UA-Compatible" content="IE=edge" />