有没有办法在浏览器特定的条件CSS * .css文件? [英] Is there a way to do browser specific conditional CSS inside a *.css file?

查看:115
本文介绍了有没有办法在浏览器特定的条件CSS * .css文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有一种方法可以在* .css文件中执行浏览器特定的条件CSS?我想在同一个物理文件中定义所有的样式。

Is there a way to do browser specific conditional CSS inside a *.css file? I want to define all of the styles inside of the same physical file.

推荐答案

有一种方法可以在IE利用浏览器和@import中的错误。我看到的最佳方法是这里,感谢bobince(绝对打败了我的回答,呵呵)。

There is a way to do it in IE by taking advantage of bugs in the browser and @import. The best method I've seen is here, courtesy of bobince (and definitely beat out my answer, heh).

一般来说,没有。即使条件注释是特定浏览器的IE。

In general though, no. Even conditional comments are browser-specific to IE.

这篇关于有没有办法在浏览器特定的条件CSS * .css文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆