1

I have a website developed in Visual Studio, and tested with the IIS Express coming with VS. Everything is fine in the testing phase. The website looks good both in Firefox and IE.

But when uploaded to the IIS Server, the site is only normally rendered in Firefox. Crappy in IE.

I found the DOCTYPE was automatically changed from "Transitional" into "Strict". Why do they change this? And how can we force the IIS to display correctly?

Blaise
  • 18,108
  • 20
  • 89
  • 154

2 Answers2

1

Are you on the same domain? If so, IE automagically forces one into intranet-friendly compatibility mode. See this answer for a method to force it to avoid that.

Community
  • 1
  • 1
Wyatt Barnett
  • 15,444
  • 3
  • 31
  • 51
  • Still don't know the meaning of those magic codes. But it works. Wyatt, you are truly a God-sent! – Blaise Nov 04 '11 at 20:47
  • You are sending IE a HTTP header to tell it which rendering engine to use -- IE9 uses compatibility mode when the site is in your local intranet zone unless explicitly ordered not to. – Wyatt Barnett Nov 04 '11 at 22:12
0

Your document should contain the doctype. Don't let IIS do it at all.

Diodeus - James MacFarlane
  • 107,156
  • 31
  • 147
  • 171