2

I have an asp.net website that is used by many clients just fine. I recently had a customer who switched to Win7 and IE10. He tells me that whenever he tries to view my site that he is prompted for compatibility mode. I attempted to reproduce this in my lab on several Win7 boxes with IE10. No luck.

So I have a few questions:

  • Has anyone seen IE10 on Win7 selectively prompt for compatibility mode?
  • What are the disadvantages of just configuring his browser to always use compatibility mode?

Thanks.

kmarks2
  • 4,755
  • 10
  • 48
  • 77

2 Answers2

5

This happens pretty often, not only about IE 10, but also to IE 9. As for me, it's better to run away from compatibility mode, as it often breaks your page look and functionality.

Good solutions for this - use web.config of your site:

<httpProtocol>
<customHeaders>
<clear />
<add name="X-UA-Compatible" value="IE=edge" />
</customHeaders>
</httpProtocol>

(used it in web.forms project).

Or global.asax

protected void Application_BeginRequest()
{
    Response.AddHeader("X-UA-Compatible", "IE=edge");
}

(used it in one of my MVC projects).

And here is good reply about compatibility mode:

Why does IE9 switch to compatibility mode on my website?

Community
  • 1
  • 1
Dmytro
  • 1,590
  • 14
  • 14
  • I think in the short term I am going to simply change this one clients compatibility mode settings, but as soon as I can actually reproduce it on my side I am going to do this X-UA-Compatible whatnot. – kmarks2 Aug 09 '13 at 15:03
2

If you are attempting to reproduce the error with a deployment within your intranet IE might default your settings (I assume the user is not on the same intranet as your deployment). You can reach the settings for this in IE (press Alt+T for the Tools menu) Tools>Compatibility View Settings.

This has helped me in the past for such problems, although I would be delighted to see others' answers too.

Nameless One
  • 1,615
  • 2
  • 23
  • 39
  • Excellent comment. I had not thought of this. And sure enough my intranet sites force to compatibility mode. Unfortunately when I turn that off I still don't get prompts for compatibility mode. – kmarks2 Aug 09 '13 at 15:01