What browsers support CSS #parent > .direct-child notation? (no jQuery)

前端 未结 3 810
广开言路
广开言路 2021-01-04 06:22

As far as I know, the > (#test>div) means that the div is required to be a direct child of #test.

Where a space (#tes

相关标签:
3条回答
  • 2021-01-04 06:36

    You can find information for all selectors at http://www.quirksmode.org/css/contents.html For your questions the supported browsers are the following:

    IE 7, IE8, IE9 pr3, FF 3.0, FF 3.5, FF 3.6, FF 4b1, Saf 4.0 Win, Saf 5.0 Win, Chrome 4, Chrome 5, Opera 10.10, Opera 10.53 and Opera 10.60

    Edit: Since it's 2015 I would suggest to have as reference for such questions the can I use? website. For example you can find more info for child selector.

    0 讨论(0)
  • 2021-01-04 06:41

    FF2+, IE7+, Opera/Safari/Chrome ( any modern version of the latter ) should support the child selector.

    0 讨论(0)
  • 2021-01-04 06:48

    It works great on IE7 (at least) unless you use #div > *, as I've just found out.

    0 讨论(0)
提交回复
热议问题