I'm trying to use animate()
to change the height and opacity of a div
. The div has an image background in CSS. It works fine on Firefox and Safari, but when I test it in IE the background is being removed. This is my code:
if (jQuery.support.opacity) { jQuery('#list_box').animate({opacity: '1',height: '300px',top: newTop},{duration: 300}); } else { jQuery('#list_box').animate({filter: 'alpha(opacity=100)',height: '300px',top: newTop},{duration: 300}); }
How can I fix this problem?
I was under the impression that jQuery did the whole opacity support thing for you. Does this work for all browsers?
$('#list_box').animate({opacity: '1',height: '300px',top: newTop},{duration: 300});
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With