Fra*_*dev 5 css internet-explorer browser-detection
我想具体说明浏览器如chrome,opera,firefox使用特定的css文件和浏览器作为IE(从版本7到10)使用另一个css文件.
我怎么能具体这个?
谢谢大家的帮助!圣诞节快乐!
您可以使用 IE 条件注释,如下所示:
<!--[if IE]>
According to the conditional comment this is IE<br />
<![endif]-->
Run Code Online (Sandbox Code Playgroud)
所以你可以使用这样的东西:
<head>
<link href="styles.css" rel="stylesheet" type="text/css" />
<!--[if lte IE 10]>
<link href="iestyles.css" rel="stylesheet" type="text/css" />
<![endif]-->
</head>
Run Code Online (Sandbox Code Playgroud)
您可以在这里了解更多关于它们的信息