Fading issues in Internet Explorer 7 when using jQuery

前端 未结 5 1674
执念已碎
执念已碎 2020-12-21 11:07

I\'m using jQuery on a site that I\'m working on and everything works fine - except in Internet Explorer 7 (and previous versions, but the site doesn\'t support them). Take

5条回答
  •  情书的邮戳
    2020-12-21 11:30

    Font Cleartype issue with fade in fade out jQuery

    This is a really good explanation of the exact problem. It has to do with the clear type font in IE. This is a fix I've used.

    Example:

    // This causes this text glich
    $("#message").fadeIn();
    
    // This will fix it
    document.getElementById("#message").style.removeAttribute("filter");
    

    Fix is to remove the filter.

    $('#message').fadeIn(function(){
        this.style.removeAttribute("filter");
    });
    

    Source

提交回复
热议问题