I am wondering how do you stop people who are using IE 8 from going to Compatibility mode?
<meta http-equiv="X-UA-Compatible" content="IE=8" />
I found this tag and I think this forces people to stay in IE-8 mode but I am not too sure and can't check as I have IE 9.
If people are in IE 9 mode I force them to not go into IE 8 or IE 7 Compatibility mode?
I tried to put the above line in my code and went to IE 9 -> Tools -> Compatibility View(Grayed Out)
but "Compatibility View Settings" was not grayed out and it seems you could add the site through there.
So should that not disable?
The answer given by FelixFett worked for me. To reiterate:
I have it as the first 'meta' tag in my code. I added 10 and 11 as those are versions that are published now for Internet Explorer.
I would've just commented on his answer but I do not have a high enough reputation...
Adding a tag to your page will not control the UI in the Internet Control Panel (the dialog that appears when you selection Tools -> Options). If you're looking at your homepage which could be google.com, msn.com, about:blank or example.com, the Internet Control Panel has no way of knowing what the contents of your page may be, and it will not download it in the background.
Have a look at this document on MSDN which discussed compatibility mode and how to turn it off for your site.
Another way to achieve this in Apache is by putting the following lines in
.htaccess
in the root folder of your website (or in Apache's config files).This requires that you have the
mod_headers
andmod_setenvif
modules enabled.The extra HTTP header only gets sent to IE browsers, and none of the others.
should force your page to render in IE8 standards. The user may add the site to compatibility list but this tag will take precedence.
A quick way to check would be to load the page and type the following the address bar :
If you see IE7 in the string, it is loading in compatibility mode, otherwise not.
All you need is to force disable C.M. in IE - Just paste This code (in IE9 and under c.m. will be disabled):
Source: http://twigstechtips.blogspot.com/2010/03/css-ie8-meta-tag-to-disable.html
In JSF I used: