Override ‘Display Intranet sites in Compatibility View’

I recently faced this issue, where the page was not rendering properly in the company’s lan in Internet Explorer 8 (IE 8) (thanks to some advanced jQuery plugins incorporated). After sacrificing 1.5 hours of my life on this problem, I figured out the solution. The problem is, by default, the checkbox (present in menu->tools) ‘View Intranet sites in compatibility view’ is checked, which tells IE-8 (or later) to render the page assuming page is built acc to IE-7 standards.

The Solution:-
If you are using IIS as your server, then adding the following meta tag to your pages might solve your problem: –

See this link for details – Solution if using IIS

But in my case I was using apache-tomcat, the solution for which is adding header to response from backend. The same can be achieved by using a filter/request interceptor through which every request will pass which is generally used to verify whether the user is still logged in or not. This is the place where we can modify the header to the response.

I presume, one knows how to add a request interceptor in a Java based web application. If you don’t have much idea on how to do this then I would encourage you to visit this link –

How to add RequestInterceptor to a Spring based application

Similarly, you can easily find links to add a filter in a Struts or any other framework based application.

Now we just need to add a single line to the class representing our filter/request interceptor. Please see below code snippet:-

//before the actual handler will be executed
public boolean preHandle(HttpServletRequest request,
HttpServletResponse response, Object handler)
throws Exception {

// Some logic

// below statement ensures IE trusts the page formatting and will render it acc. to IE 8 standard.
response.addHeader("X-UA-Compatible", "IE=8"); 

return true;

I have myself verified above solution works for IE-8.

Hope this small fix saves someone’s time.


Spotify Singapore

As of present date, spotify is not accessible in either India or Singapore, but there are ways and tricks to make it work. This link gives you a step by step guide to make it work in singapore. No doubt it should work in India also.