Ticket #4503 (closed bug: wontfix)
in IE6 load handler for img element is called many times for animated gifs
| Reported by: | jdavidn | Owned by: | |
|---|---|---|---|
| Priority: | major | Milestone: | 1.4 |
| Component: | ajax | Version: | 1.3.2 |
| Keywords: | Cc: | ||
| Blocking: | Blocked by: |
Description
If a DOM img element is assigned a 'load' callback function and if subsequently that img is loaded with an animated gif then the load function is called infinitely many times in IE 6 whenever the animated gif repeats its animation cycle. This unexpected behavior does not exist in FireFox.
I have not tested it with IE7.
I have included a sample html page that demonstrates this bug.
Attachments
Change History
Changed 4 years ago by jdavidn
-
attachment
animated-gif-bug.zip
added
comment:1 Changed 4 years ago by dmethvin
- Status changed from new to closed
- Resolution set to wontfix
This definitely seems like a long-standing browser bug; here's a related issue from 2005:
http://bytes.com/groups/javascript/150332-problem-image-onload-event-firing-too-early-ie
It doesn't seem like something jQuery could easily fix, since for instance you might change the src attribute and want the load event to fire several times. You could use .one() or unbind the load event when you've determined that the image has correctly loaded.
Please follow the bug reporting guidlines and use jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

unzip file and open loads-animated.html in IE 6 to see bug