{"id":2091,"date":"2012-02-08T15:19:54","date_gmt":"2012-02-08T15:19:54","guid":{"rendered":"http:\/\/www.simonbattersby.com\/blog\/?p=2091"},"modified":"2012-06-20T14:25:31","modified_gmt":"2012-06-20T13:25:31","slug":"jquery-fadeout-in-firefox-10","status":"publish","type":"post","link":"https:\/\/www.simonbattersby.com\/blog\/2012\/02\/jquery-fadeout-in-firefox-10\/","title":{"rendered":"jQuery fadeOut in Firefox 10"},"content":{"rendered":"<p>Having an odd week this week.<\/p>\r\n<p>While viewing a client&#8217;s site today in Firefox 10 I noticed that the crossfade on the site, loaded just before Christmas, wasn&#8217;t quite right &#8211; the images should crossfade into one another (using <a href=\"\/blog\/simple-jquery-image-crossfade\/\">this script<\/a>), but what happened was the image faded to black and then the next image appeared. I observed the same effect on the <a href=\"http:\/\/malsup.com\/jquery\/cycle\/\">malsup cycle plugin<\/a>, used elsewhere on the site.<\/p>\r\n<p>Now the same script works fine in Opera 11 and Chrome, and it works fine in Firefox 10 on my demo page listed above. So what&#8217;s the difference? The only difference is that one image has a border, and one doesn&#8217;t. Add the border and the crossfade works fine, take it away and it doesn&#8217;t. Here&#8217;s a <a href=\"\/demos\/ff10_fadeout.htm\">cut down illustration<\/a> &#8211; the left hand image has a border and fades to transparent, the right hand image has no border and fades to black then transparent.<\/p>\r\n<p>Having checked a couple of other sites I&#8217;ve built, if the image is wrapped in div, all seems to be OK as well, it&#8217;s just an issue with images.<\/p>\r\n<p>This is only an issue in Firefox 10 as far as I can see. FF9 is fine.<\/p>\r\n<p>I&#8217;ve logged this as a <a href=\"http:\/\/bugs.jquery.com\/ticket\/11308\">bug with jQuery<\/a>. If you&#8217;ve come across the same issue please leave a comment below, or, if you&#8217;ve got a spare second and Firefox 10, have a look at the test page and let me know if you see the same thing. Apparently it&#8217;s OK on Mac\/OS X. I&#8217;m on W7 Pro 64-bit.<\/p>\r\n<p><strong>Update 10 February<\/strong> Thanks to Oblik for the updates below &#8211; this is reported as a Firefox bug as well. It also seems that applying <code>background-color<\/code> to the image also solves the problem. I&#8217;ve further noted that this does <strong>not<\/strong> affect a different machine running W7 Home with FF10 &#8211; the links suggest it may be related to the graphics card.<\/p>\r\n<p><strong>Update 18 February<\/strong> This looks like it&#8217;s mostly likely to get resolved by a Firefox update to me. I&#8217;ve noticed the problem today on another couple of sites. It&#8217;s now being logged under <a href=\"https:\/\/bugzilla.mozilla.org\/show_bug.cgi?id=723484\">this ticket.<\/a><\/p>\r\n<p><strong>Update 24 April<\/strong> Still not fixed in FF11&#8230;I&#8217;ve noticed the problem a lot on a wide variety of sites. Looks like it might be scheduled for a fix in FF13.<\/p> \r\n<p><strong>Update 20 June<\/strong> Fixed in FF13!!<\/p>","protected":false},"excerpt":{"rendered":"<p>Having an odd week this week. While viewing a client&#8217;s site today in Firefox 10 I noticed that the crossfade on the site, loaded just before Christmas, wasn&#8217;t quite right &#8211; the images should crossfade into one another (using this script), but what happened was the image faded to black and then the next image [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[26,20],"class_list":["post-2091","post","type-post","status-publish","format-standard","hentry","category-web-design-and-build","tag-firefox-10","tag-jquery"],"_links":{"self":[{"href":"https:\/\/www.simonbattersby.com\/blog\/wp-json\/wp\/v2\/posts\/2091","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.simonbattersby.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.simonbattersby.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.simonbattersby.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.simonbattersby.com\/blog\/wp-json\/wp\/v2\/comments?post=2091"}],"version-history":[{"count":0,"href":"https:\/\/www.simonbattersby.com\/blog\/wp-json\/wp\/v2\/posts\/2091\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.simonbattersby.com\/blog\/wp-json\/wp\/v2\/media?parent=2091"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.simonbattersby.com\/blog\/wp-json\/wp\/v2\/categories?post=2091"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.simonbattersby.com\/blog\/wp-json\/wp\/v2\/tags?post=2091"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}