css3 Selectors Cheatsheet PDF
css3 Selectors Cheatsheet PDF
Universal selector
*{}
Type selector
E{ }
Attribute selectors
E[foo] { } E[foo^="bar"] { } E[hreflang|="en"] { } E[foo="bar"] { } E[foo$="bar"] { } E[lang|="en"] { } E[foo~="bar"] { } E[foo*="bar"] { }
Internet Explorer 7 Internet Explorer 6 Firefox 2 Opera 9 Safari 2 * E E[foo] E[foo="bar"] E[foo~="bar"] E[foo^="bar"]
Structural pseudo-classes
E:root { } E:nth-of-type(n) { } E:last-child { } E:only-child { } E:nth-child(n) { } E:nth-last-of-type(n) { } E:first-of-type { } E:only-of-type { } E:nth-last-child(n) { } E:first-child { } E:last-of-type { } E:empty { }
E[foo$="bar"] E[foo*="bar"] E[hreflang|="en"] E[lang|="en"] E:root E:nth-child(n) E:nth-last-child(n) E:nth-of-type(n) E:nth-last-of-type(n) E:first-child
Structural pseudo-classes
E:link { } E:visited { }
Class selectors
E.warning { }
ID selectors
E#myid { }
Negation pseudo-class
E:not(s) { }
Descendant combinator
EF{ }
Child combinator
E>F{ }
supported
CSS Level 3 Selectors WWW WATCH http://www.w3.org/TR/css3-selectors http://hyper-text.org/archives/2007/01/css3_selector_cheatsheet.shtml