How to workaround: IE6 does not support CSS “attribute” selectors

前端 未结 7 958
青春惊慌失措
青春惊慌失措 2020-12-18 22:21

One of the projects which I am working uses CSS \"attribute\" selector [att]

CSS Selectors

which is not supported by ie6: Support for CSS selectors in IE6 (

相关标签:
7条回答
  • 2020-12-18 23:25

    Since IE6 is essentially limited to:

    • class selectors
    • ID selectors
    • (space) descendant selectors
    • a:-only pseudo-selectors

    your only options are:

    • Use more classes to identify your elements
    • Use JavaScript (strongly not recommended except in highly specialized cases)

    I find it very helpful to take advantage of the ability to assign multiple classes to an element by separating them with a space: class="foo bar"

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