gpt4 book ai didi

javascript - 让 Internet Explorer 识别 "advanced"CSS 选择器

转载 作者:塔克拉玛干 更新时间:2023-11-02 21:55:47 28 4
gpt4 key购买 nike

是否存在任何 JavaScript 库以某种方式使 Internet Explorer(无特定版本)识别高级 CSS 选择器,例如 input[type="text"]

我讨厌为了适应 IE 而向 HTML 对象添加额外的类。

最佳答案

我不敢相信这不是建议的:

http://selectivizr.com/

selectivizr is a JavaScript utility that emulates CSS3 pseudo-classes and attribute selectors in Internet Explorer 6-8. Simply include the script in your pages and selectivizr will do the rest.

Selectivizr works automatically so you don't need any JavaScript knowledge to use it — you won't even have to modify your style sheets. Just start writing CSS3 selectors and they will work in IE.

您还需要包含您选择的标准 JavaScript 库,您可能已经这样做了。

关于javascript - 让 Internet Explorer 识别 "advanced"CSS 选择器,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6333221/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com