I want to use a separate CSS sheet on my webpage for Chrome and Safari than the one used for all other types of borwser. Earlier I used conditional comments for IE, for example:
<!--[if !IE]><link rel="stylesheet" type="text/css" href="style.css"><!--<![endif]--> <!--[if IE]><link rel="stylesheet" type="text/css" href="style2.css"><![endif]-->
but I want the above to work for Chrome and Safari. Is it possible?
Conditional comments only work in IE.
This is a creative way to solve this problem. I learned it from here
@media screen and (-webkit-min-device-pixel-ratio:0) { /* CSS Statements that only apply on webkit-based browsers (Chrome, Safari, etc.) */ }
Mozilla also has a specific provider.
@media screen and (min--moz-device-pixel-ratio:0) { /* Firefox browser based CSS goes here */ }