Solutions Log

So I only have to figure things out once.

Dealing With the IE 7 (and 8) Transparency Bug With jQuery

I found out this morning that you can’t use jQuery’s fadeIn or fadeOut in IE 7 or 8 on elements that have transparent pngs as backgrounds because the animation will make the transparency turn black. It’s a good thing browser detection is built into jQuery(!).

if ($.browser.msie && $.browser.version < 9 ) {
    $('#whatever').hide();
} else {
    $('#whatever').fadeOut();
}

Excellent.

Sources

Comments