Click here to Skip to main content
15,918,808 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi All,

I have an asp.net web application hosted in IIS. I am using IE 9 browser. I have a bit of confusion regarding IE browser mode and document mode. Because if I am using 'localhost' word in the login URL(i.e. http://localhost/MyWebApplication/Login/Default.aspx) of application then it opens with 'IE 9' browser mode and 'IE 9 standard' document mode, which is fine.

But when I open the same application with same client browser version having my IP in the URL(i.e. http://255.255.255.255/MyWebApplication/Login/Default.aspx) then it opens with 'IE 9 Compatibility view' browser mode and 'IE 7 standard' document mode.

So, now I am not sure how IE internally decides browser mode and document mode based on the URL. What is the difference in having IP or 'localhost' in the URL?

Also, I tried adding meta tag in my pages to force the IE to work with specific document mode, it works fine. But, by default there no meta tag or any other configuration which helps IE to decide document mode or browser mode.

Can anyone help me in this?..

Thanks in advance...:)...
Posted
Comments
nikhil-vartak 18-Jul-13 6:27am    
Check if this is of any help!

http://webmasters.stackexchange.com/questions/13622/ie9-changes-browser-mode-based-using-domain-name-or-ip-address-for-the-url
Bernhard Hiller 18-Jul-13 8:38am    
Nice link. Once again it showed that attempts of browser sniffing are bad.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900