I have ran into a slight issue with IE 7/8's compatibility mode. I need to force this off for users viewing my Drupal site. I found what I believe to be a fix, however I am unsure how to implement this change. The solution found is the meta tag: meta http-equiv="X-UA-Compatible" content="IE=edge" How can I place this change into the head of each of the pages on my site?

Comments

Issue resolved, but frustration remains. In order to circumvent this, I had to place a directive directly into Apache. This option works, but is not exactly how I was hoping to resolve.

Is there a way to modify meta tag data in Drupal 7? I know you could accomplish this with a stringreplace in D6. Any chance something similar in 7?

Very nice! This is exactly what I was after. Thank you.

Hi there!

I have run into an issue that looks like something you may have.
I looked at the api page mentioned above, however, being a noob at both drupal and php I am still foggy as an autumn morning.

Could you please tell me:
How did you actually solve your problem of forcing the IE "compatibility mode" off.

It is quite embarrassing to show my site to my friend and say "uh, oh it should look like this really."

BTW, the Display suite is what gives me the "problem" in my case as it uses the ASIDE element and IE does not render it on the side unless the compatibility mode is off. Actually I am not sure what IE 7 will do as I have no access to that version.

Thanks,
Gábor

I actually ended up having to disable compatibility mode via Apache. I'm not sure if you have this sort of access, as I am the server admin as well as the web dev.

The following is what I found -

Edit httpd.conf and allow
“LoadModule headers_module modules/mod_headers.so” by uncommenting.
Or use the a2enmod command to enable selected the header module.
Add the following configuration statements to httpd.conf or any other virtual host that requires that extra rendering header:

Header set X-UA-Compatible: “IE=edge″

Restart Apache and the extra X-UA-Compatible headers should be send with each page rendered.

Credit for the fix goes to Chin Young @ this post.

Thats great - thanks, worked fine in my preprocess-html.inc file using omega theme...

Drupal development | SEO optimised build | Social Media Marketing

Thank you - soon I'll have a VPS space where I can implement this.

we have success with inserting:

Header set X-UA-Compatible "IE=Edge,chrome=1"

in htaccess after : IfModule mod_headers.c

in the httpd.conf we have succes with

Header set X-UA-Compatible: IE=edge

- without the two "