Sony packman
Sony packman

Reputation: 840

Firefox doesn't play animated gif properly (works fine in Chrome)

I have an animated gif image that gets swapped to another animated gif onclick. So far everything works. But when I want to make another change (to a third animated gif) then firefox wont play the third gif animation at all. In Chrome it works fine.

I uploaded a test file so you can see for your self:

http://fastertutorials.com/stuff/test.html

In firefox, when you click on the smiley it will start spinning. But if you click a second time then it should explode. But the explosion never plays in firefox, only in Chrome.

Upvotes: 3

Views: 7532

Answers (2)

user187228
user187228

Reputation:

This is almost certainly a bug in Firefox 12 and 13, but luckily it appears to be fixed in 14.

Stragely, having another instance of the image present seems to fix the problem. A possible (but very hacky) workaround might be to add another instance of polly.gif to the bottom of the page and set its height and/or width to 0. Setting display to none doesn't work.

You can try the workaround here: http://jsfiddle.net/tH5TC/

Upvotes: 1

Mark Price
Mark Price

Reputation: 590

I think this may be a firebug error. try this:

  1. open firebug
  2. load page
  3. click on image twice
  4. If you get a static sad face open firebug html console
  5. Open the <body> tag
  6. hover over the image tag's id

The animation should then start to play.

Upvotes: 0

Related Questions