Charlie's Blog

  • home
  • programming
  • music
  • 2011-08-17
  • css, html, programming
  • 3 Comments

How to force quirks mode in IE7 (while keeping to standards mode in IE8+)

If you put an HTML comment above the doctype declaration, it causes IE7 to enter quirks mode, but not any other browsers.

<!-- This forces quirks mode in IE7 only -->
<!doctype html>
<html>
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=Edge">
    <title>Quirks mode in IE7!</title>
  </head>
  <body></body>
</html>

Read more

Posts navigation

Previous page 1 2

Powered by WordPress. Reyl Lite designed by Quema Labs.