Open hjzheng opened 10 years ago
CSS选择器 (Chun Lin Yang) 大家在使用CSS选择器的时候,由于考虑浏览器的兼容性,基本上使用的都是些简单的选择器,不但错过一些高级选择器的使用,还错误的认为IE8不支持某些高级选择器,所以希望下面的选择器兼容表格,可以让你大胆的使用某些高级选择器。
*
#id
#header
.class
.item
Element
p
Element,Element
div,p
[attribute]
[target]
[attribute=value]
[target=_black]
[attribute~=value]
[class~=item]
[attribute*=value]
[title*=flower]
[attribute^=value]
[title^=a]
[attribute$=value]
[title$=z]
Element+Element
div+p
Element~Element
div~p
Element Element
div p
Element>Element
div>p
:link
a:link
:visited
a:visited
:active
a:active
:hover
a:hover
:foucs
a:focus
:checked
input:checked
:enabled
input:enabled
:disabled
input:disbaled
:target
a:target
:nth-child
li:nth-child(2)
:nth-last-child
li:nth-last-child(2)
:nth-of-type
li:nth-of-child(2)
:nth-last-of-type
li:nth-last-of-type(2)
:first-child
li:first-child
:first-of-type
li:first-of-type
:last-child
li:last-child
:last-of-type
li:last-of-type
:only-child
li:only-child
:only-of-type
li:only-of-child
:empty
li:empty
:not
div:not(p)
::before
div::before
::after
div::after
::first-line
p::first-line
::first-letter
p::first-letter
Examples (Hao Ju Zheng)
让IE8支持CSS3选择器 (Hao Ju Zheng) http://selectivizr.com/
Here is official website for Selectors Level 3. http://www.w3.org/TR/selectors/#target-pseudo
CSS属性完全兼容列表:http://csscreator.com/properties IE属性兼容列表:http://msdn.microsoft.com/zh-cn/library/cc351024(v=vs.85).aspx
关于CSS 选择器 PPT:http://get-set.cn/CUF_PPTs/CSS_Selector.html
CSS选择器 (Chun Lin Yang) 大家在使用CSS选择器的时候,由于考虑浏览器的兼容性,基本上使用的都是些简单的选择器,不但错过一些高级选择器的使用,还错误的认为IE8不支持某些高级选择器,所以希望下面的选择器兼容表格,可以让你大胆的使用某些高级选择器。
*
*
#id
#header
.class
.item
Element
p
Element,Element
div,p
[attribute]
[target]
[attribute=value]
[target=_black]
[attribute~=value]
[class~=item]
[attribute*=value]
[title*=flower]
[attribute^=value]
[title^=a]
[attribute$=value]
[title$=z]
Element+Element
div+p
Element~Element
div~p
Element Element
div p
Element>Element
div>p
:link
a:link
:visited
a:visited
:active
a:active
:hover
a:hover
:foucs
a:focus
:checked
input:checked
:enabled
input:enabled
:disabled
input:disbaled
:target
a:target
:nth-child
li:nth-child(2)
:nth-last-child
li:nth-last-child(2)
:nth-of-type
li:nth-of-child(2)
:nth-last-of-type
li:nth-last-of-type(2)
:first-child
li:first-child
:first-of-type
li:first-of-type
:last-child
li:last-child
:last-of-type
li:last-of-type
:only-child
li:only-child
:only-of-type
li:only-of-child
:empty
li:empty
:not
div:not(p)
::before
div::before
::after
div::after
::first-line
p::first-line
::first-letter
p::first-letter
Examples (Hao Ju Zheng)
让IE8支持CSS3选择器 (Hao Ju Zheng) http://selectivizr.com/