开发者

Are these selectors part of CSS 2.1 or CSS 3?

Are these selectors part of CSS 2.1, CSS 3, or both?

E[att^="val"]
E[att$="val"]
E[att*="val"]
E:last-child
E ~ F

Are these all the available selectors in CSS? Please tell me which selector is part of which CSS version?

*
E
.class
#id
E F
E > F
E + F
E[attribute]
E[attribute=value]
E[attribute~=value]
E[attribute|=value]
:first-child
:lang()
:before
::before
:after
::after
:first-letter
::first-letter
:first-line
::first-line
E[attribute^=value]
E[attribute$=value]
E[attribute*=value]
E ~ F
:root
:last-child
:only-child
:nth-child()
:nth-last-child()
:first-of-type
:last-of-type
:only-of-type
:nth-of-type()
:nth-last-of-type()
:empty
:not()
:target
:enable开发者_JAVA技巧d
:disabled
:checked


All CSS 3.

  • CSS 3 selectors

  • CSS 2.1 selectors

The last one E ~ F is the general sibling combinator.

See the quirksmode.org compatibility table for info on which selector is supported by which browser.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜