Azure web sites rendering issue - asp.net-mvc

I have an MVC development which works fine when run locally. When deployed to an Azure Web Site, I'm seeing the same results (as expected) in Firefox, Chrome, IE8, and others. When viewed in IE11 (the same browser that I'm using to view the site locally), the layout is all over the place.
It seems that when Azure Web Sites renders the site, the IE11 browser is dropping into "7 (Default)" Document Mode. Pressing F12 and resetting to Edge gets the rendering back to how it should be.
I'm struggling to work out what is going on in Azure Web Sites that is causing this behaviour. I'm thinking it's a compatibility setting somewhere and any pointers would be appreciated.
Thanks, Nick.

As explained by #ahmelsayed above, adding the
<meta http-equiv="X-UA-Compatible" content="IE=Edge" />
tag has fixed the problem. Thanks for the support.

Related

How to force main page run IE11 and iFrame run IE7

I have a main application, made with Microsoft .NET Framework 4.7 (MVC) that is forced (and must) to run with Compatibility Mode IE11.
Inside that application, there is a specific page with a iFrame that run a .Net Framework 1.1 application that must run in Compatibility Mode IE7.
The problem is that both (main and iframe) are running with compatibility mode IE11 and, because of that, frame application doesn't run properly.
At the moment, I've already tried to force iframe application to run in IE7 by adding to the IIS HTTP Headers the following pair key-value:
Custom header name: 'X-UA-Compatible'
Custom header valuebox: 'IE=EmulateIE7'
However it didn't solve my problem and i am out of ideas now.
Any suggestion?
Thank you in advance!
I think you should you meta tags to specify the compatibility mode (not sure if the http header do the same thing). According to this answer it should be posible:
Main web page in standard mode, iframe in compatibility mode: any issues?
Here is quite thorough documentation of what are the options:
What does <meta http-equiv="X-UA-Compatible" content="IE=edge"> do?
Please check this similar thread, try to use the IE browser Quirks Mode.
In the iframe content page, omit Doctype and add
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />

MVC site not showing correctly on IE11 browser from IIS, it shows correctly when IE11 is called from .NET IDE

My site works ok in Chrome and Firefox but i found some problems on IE11 from IIS (but it shows ok on IE11 when called from .NET IDE). main Menu page shows like this, as if it were taking a wrong Bootstrap version:
This is how the same site looks when called from IDE:
So this only happens on IE11, other browsers show this ok. This uses bootstrap 4.31, MVC 5. I don't think there is a real need to show it here since it doesn't look it's related to code (imo it has to be something IE11 specific) but i can add code in case it's needed.
Thanks!
Fixed, the problem was because the browser was using IE7 compatibility mode. Fixed by adding this in headers:
<meta http-equiv="x-ua-compatible" content="IE=11">
More info about this:
Here

MVC app works fine in chrome, Firefox but not in IE11

I have a small MVC app, all this app must do is to take search string parameter via text-box and search the database return the data based on the parameter entered. This app works fine in the two of the browser that I have on my machine, it works in chrome and firefox but goes to complete freeze on IE11, it freezes so much so that it cannot even open developer tools nor respond to any click on the landing page.
I am not even too sure what code should I post because I doubt it has something to do with it and if does go down to code I am not sure which part because like I said it works perfect in chrome and firefox
I tried adding the line <meta http-equiv="X-UA-Compatible" content="IE=edge"> on the layout page but that made no difference whatsoever
Typically inability to open dev tools in a browser indicates that something intensive is running in a background. Try to open dev tools prior to entering URL of your application. Sometimes you can find some request looping forever, or wrong javascript.

How to force to open a Page in Document Mode as IE8

We have deployed our webapp, which was developed with JSF, Spring and Hibernate on Tomcat server in our internal network (intranet). When I test in my application in local it's working fine.
But once I deploy to DEV I come across style issues. When I have two dropdowns one after another, the top dropdown overlaps with another one.
This happens when I have Document Mode set to "IE7 standards." When I change Document Mode to "IE8 standards," everything works fine.
To force Document Mode to IE8 standards, I tried this meta tag in my section of the HTML document according to this link, but it didn't work for me:
<meta http-equiv="X-UA-Compatible" content="IE=edge" >
How can I force my page to render according to IE8 standards on the intranet? Does my application render in IE8 standards on the internet?
EDIT :I see something in my develoer tools.Even though I kept my <meta> it after <head> but my primefaces styles and scripts are loading before to that.How can I resolve this?
Odd, this item was posted yesterday, not sure if it applies to your situation:
IE 8 will ignore the x-ua-compatible setting if it comes after the stylesheets. In order for IE to acknowledge the meta setting, put it at the top.
I am glad to tell I am finally able to resolve this issue by using this link in primefaces.And this post also helped to do it through entire application
http://blog.primefaces.org/?p=1433

IIS6 with IE8 not loading ASP.NET MVC site properly

This is odd, and I hope I explain it correctly.
When I debug locally with VS2008, IE8 looks like FF and Chrome (minus the obvious). It works well, and I'm happy.
When I use IE8 with our IIS6 box (Win2003) or Cassini, buttons aren't aligned, javascript errors occur, and some other CSS anomolies occur: Table cells missing colored borders, div elements having different dimensions by 2-3pixels.
If anyone has come across this, please let me know - It's completely baffling me
IE8 runs in different modes depending on if it's visiting a site running on localhost vs another server. It's weird, I know. I've run across this issue before as well. Use the developer tools (F12) and check which mode (Quirks, IE7 Standard, IE8 Standard, IE8 Compatibility) the browser is running in.
Could it be an old CSS file that is cached on the client?

Resources