Compatibility Mode (Internet Explorer)

Ok, so i’m making this website and whenever I open it up in internet explorer (only when its online - on my local computer it looks fine) the page is all jumbled up.

I found the problem is “Compatibility Mode”. Once I click that, the webpage shows up just fine. But I want it to look this way to every user no matter what. Is there a script that anyone knows about so that onload it will “click” Internet Explorers Compatibility Mode button?

http://www.trileafdesigns.com/a_marketing.html

The compatibility mode option is in IE8 so that it can handle incorrectly written web pages that try to apply all the hacks that are needed to get it to work in IE7 in IE8 as well and so messes up the page. If it is written to work properly in modern browsers and the IE7 hacks specifically target IE7 then the compatibility mode is not needed. So unless you stuffed up pages written before IE8 came out you shouldn’t need to bother with compatibility mode for your pages. Needing it on tells you that you stuffed up the way your page is coded.

it still looks bad on some people Internet Explorer. There’s got to be a script out there that automatically clicks the “Compatibility Mode” button. Yeah I just added that flash poll so the menus should be behind it for now, but that IE Page being messed up almost gave me a heart attack.

Ok, the problem is that my internet explorer/other peoples browser ARE running in compatibility mode by default, I need to turn theirs off onload. That’s wht happening

I am actually getting the reverse effect - by default the page looks just fine in IE, but when i hit the button, it breaks.

Seems that your “Compatibility Mode Button” is on by default.

P.S. check it in FF - doesn’t look well there.

Start by getting your html valid - it’s a mess, and that’s the most likely reason for your problems.

Loaded your page in IE 8, works fine … no problems, no “Compatibility Mode button”, nothing. In fact, it looks bad in firefox 3.6, your menus are “under” the right sidebar (which doesn’t happen in IE :? ) - maybe set the z-index correctly.

However, a well-built web site does not need to care what people have settings on. If the site works in IE7 and IE8, then compat mode does not matter either way.

So far as I know, there is no way for a web author to affect users browsers (unless you write a virus to break into their computers, which you shouldn’t do).

Just use the following code for appropriate compatibility mode:

<head id="Head" runat="server">
   <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
   <meta content="text/html; charset=UTF-8"
http-equiv="Content-Type"/>

Where content=“IE=EmulateIE7” should be set to appropriate version.
Know it’s a bit late, but hopefully it’ll help somebody ouy there :wink:

While what you’ve put is accurate (and yes you can alter the compatibility trigger stomme - which is why some sites have no button, they just work as the author intended in either mode), the code you used isn’t perfect. Anyone wanting to render IE to a particular mode should read this article, it covers everything you need.