gpt4 book ai didi

jquery - 在 IE 8 上将背景颜色设置为透明动画

转载 作者:太空宇宙 更新时间:2023-11-04 12:15:52 25 4
gpt4 key购买 nike

我正在通过 jQuery 将 div 的 background-color 动画化为 transparent

$('div').animate('background-color', 'transparent');

在浏览器上运行良好,Internet Explorer 8 除外。我知道 background-color: transparent 在 IE 8 上运行良好。为什么在设置值动画时不起作用?

谢谢

注意:我已经使用 DevTools 检查了 div,由于某种原因,div 是 rgb(255,255,255)

最佳答案

试试这个:

$(".div").attr('style', 'background-color: transparent');

这对我有用。

在一个函数中设置它,并随时触发它!

关于jquery - 在 IE 8 上将背景颜色设置为透明动画,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28716460/

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