惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Martin Fowler
Martin Fowler
V
Visual Studio Blog
有赞技术团队
有赞技术团队
T
Tailwind CSS Blog
B
Blog
I
InfoQ
博客园 - 三生石上(FineUI控件)
阮一峰的网络日志
阮一峰的网络日志
F
Fortinet All Blogs
H
Help Net Security
博客园 - Franky
宝玉的分享
宝玉的分享
博客园 - 司徒正美
C
Check Point Blog
G
Google Developers Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
Jina AI
Jina AI
T
The Blog of Author Tim Ferriss
MongoDB | Blog
MongoDB | Blog
云风的 BLOG
云风的 BLOG
A
About on SuperTechFans
罗磊的独立博客
大猫的无限游戏
大猫的无限游戏
IT之家
IT之家

博客园 - biggates

Linux Screen 超简单用法 ldconfig gdb前端Nemiver 在Ubuntu中使用autofs自动加载Virtual Box数据空间 -lm 必须放在 gcc 命令的最后 常用WinXP小工具集合 VritualBox 数据空间使用手记 在 Google Buzz 中使用格式 x64 WAMP + Oracle 环境搭建 查看Oracle Dump文件的结构 解决 Vista 下 IceGrid 调试时的监视错误 - biggates 使用163镜像在线安装CentOS 令人痛苦的SyncML同步协议错误 C#中从WSDL文件生成Web 服务 有图有真相,百度屏蔽网站行为仍在继续 浏览器功能一览:IE曾经垃圾,现在垃圾,将来仍然很垃圾 三步实现 OpenSearch 功能 学习笔记 使用 Java 正则表达式解析 VCard
[转]CSS Hacks
biggates · 2009-04-25 · via 博客园 - biggates

 1 /***** Selector Hacks ******/
 2 /* IE 6 and below */
 3 * html #uno  { color: red }
 4  
 5 /* IE 7 and below */
 6 *:first-child+html #dos { color: red }
 7  
 8 /* IE 7 and modern browsers */
 9 html>body #tres { color: red }
10  
11 /* Modern browsers (not IE 7) */
12 html>/**/body #cuatro { color: red }
13  
14 /* Opera 9.27 and below */
15 html:first-child #cinco { color: red }
16  
17 /* Safari */
18 html[xmlns*=""] body:last-child #seis { color: red }
19  
20 /*safari 3+, chrome 1+, opera9+, ff 3.5+ */
21 body:nth-of-type(1) #siete { color: red }
22  
23 /* safari 3+, chrome 1+, opera9+, ff 3.5+ */
24 body:first-of-type #ocho {  color: red }
25  
26 /* saf3, chrome1+ */
27 @media screen and (-webkit-min-device-pixel-ratio:0) {
28  #diez  { background: #FFDECE; border: 2px solid #ff0000  }
29 }
30  
31 /***** Attribute Hacks ******/
32  
33 /* ie6 and below */
34 #once { _color:blue }
35  
36 /* ie7 and below */
37 #doce { *color: blue } /* or #color:blue */
38  
39 /* 'Modern Browsers' includes IE8, whether you agree or not.. :) */
40

原文出处:http://ajaxian.com/archives/css-browser-hacks

另有一个测试页面在:http://paulirish.com/work/csshacks.html