Last active
December 18, 2015 04:39
-
-
Save RockyMyx/5727064 to your computer and use it in GitHub Desktop.
HTML: browser-compatibility-header.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!--[if lt IE 7]> <html class="lt-ie9 lt-ie8 lt-ie7"> <![endif]--> | |
<!--[if IE 7]> <html class="lt-ie9 lt-ie8"> <![endif]--> | |
<!--[if IE 8]> <html class="lt-ie9"> <![endif]--> | |
<!--[if gt IE 8]><!--> <html class=""> <!--<![endif]--> | |
<head> | |
<meta charset="UTF-8"> | |
<title>DEMO</title> | |
<style type="text/css"> | |
/** | |
* From: http://www.paulirish.com/2008/conditional-stylesheets-vs-css-hacks-answer-neither/ | |
* There are a few problems with it though: | |
* | |
* The problems of Conditional Stylesheets: | |
* 1.Conditional stylesheets mean 1 or 2 additional HTTP requests to download | |
* 2.As they are in the the <head>, the rendering of the page waits until they’re totally loaded. | |
* 3.Also - Yahoo’s internal coding best practices do not recommend conditional stylesheets | |
* 4.It can separate a single CSS rule into multiple files. | |
**/ | |
#test{ | |
width:100px; | |
height:100px; | |
border:1px solid red; | |
} | |
.lt-ie9 #test{ | |
width:100px; | |
height:100px; | |
border:1px solid black; | |
} | |
</style> | |
</head> | |
<body> | |
<div id="test"></div> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment