The seriousness of displaying the compatibility mode button should not be overlooked. An end user unknowingly clicks it and your whole domain is rendered as IE7 for them!
The cleanest way to address this is setting the X-UA-Compatible header in a server config. html5boilerplate now sets it in .htaccess https://github.com/h5bp/html5-boilerplate/blob/master/.htaccess but how can we address this within a deliverable theme?
A few workarounds, like a second html tag or an empty conditional comment are explained here http://nicolasgallagher.com/better-conditional-classnames-for-hack-free-css/ but concludes the cleanest method is a server-side config.
This isn’t just about Zen, but any theme that uses html5boilerplate’s method of IE conditional classes on the html tag.
Related:
https://github.com/h5bp/html5-boilerplate/issues/378
Comments
Comment #1
KrisBulman CreditAttribution: KrisBulman commentedYou should probably bring up this point in #1322794: Make Stark use a responsive layout where the decision is being made to add conditional classes to core or not.. since IE7 is already dropped in D8, this would be a major issue if there is no solution taken for this.
Comment #2
droplet CreditAttribution: droplet commentedfrom my own test, .htaccess doesn't the safe way:
http://drupal.org/node/1203112#comment-5440672
Comment #3
JohnAlbinWe'd need this header for #1471382: Add IE-conditional classes to html.tpl.php as well.Sorry! posted this comment to the wrong issue! :-p
Comment #4
JohnAlbinRemoving mobile tag
Comment #5
JohnAlbinDrupal 8 just added this fix: #1203112: Add X-UA-Compatible HTTP header
It adds the necessary HTTP header as a real HTTP header instead of trying to add it via .htaccess.
Comment #6
JohnAlbinStraight port of #1203112: Add X-UA-Compatible HTTP header
http://drupalcode.org/project/zen.git/commitdiff/0c63089