I started planning to sort out the CSS selector browser support a long time ago, because CSS3 has added many very useful selectors. I have also written an article "using CSS selector to create personalized link styles" as a preliminary study of CSS selector.
Kimblim's website provides a comprehensive CSS selector support. I have translated and further organized it to simplify it as much as possible. At the same time, I also combined the list of CSS selector support compiled by the evotech website, as well as some tips I have summarized at ordinary times.
Anyone familiar with jQuery may know that the soul of jQuery is its selector. Similarly, I think selector is one of the most powerful functions of css and will be paid attention to in the near future. JQuery's selector function is inspired by the CSS3 selector, but it is currently the most compatible and easy-to-use selector. CSS selector cannot be popularized because some browsers are dragging your feet.
View "CSS selector browser support" now!
Based on the test results, the following conclusions can be drawn:
- The webkit kernel browser and operabrowser have the best support for CSS selectors. All Chrome versions support the CSS selector, and Safari3.2 and later support the CSS selector. Opera9.6 and later support the CSS selector;
- The following browsers are Safari3.0, Firefox 2.0 or earlier, and IE8 basically support CSS2.1 selector, but basically do not support CSS3 selector. Fortunately, the IE 8 browser has made a milestone and basically fully supports the CSS2.1 selector, but it still does not fully support pseudo elements;
- IE6 is the most outdated browser, and it cannot be fully supported by the CSS1 selector!
Many fans and friends of IE6 often ask me why you hate IE6 so much. Then I have to answer them with all my tongue. Now, with this table, we can justify BS IE6!
This list is not complete yet, and some pseudo elements of CSS3 are not included. I will add them as appropriate. If you find some errors or exceptions, please let me know and I will correct them as soon as possible. Thank you!
PS: update @ 2009-08-21 the CSS selector supports temporary page changes. I will release the CSS selector again after modification.