Ticket #6248 (closed bug: worksforme)
ajax calls success twice when server is unavailable
|Reported by:||kgustine||Owned by:||kgustine|
jQuery: 1.4.2; Firefox: 3.5.8
I have found that the following script calls success twice when the web server is turned off. This is proven by resetting testCount when the function is called, but incrementing it in success. If you run this in firefox and turn off the server, the alert box will first say 1, then 2.
This only happens the first time ajax is called after the server is turned off. It is not necessary to point ajax to a vaild page.
This is similar to bug #5968 and I'm sure is closely related.
This was discovered because I was clearing and setting Timeouts and Intervals inside the Success function. I was getting thousands of ghost intervals after a short period.
- Owner set to kgustine
- Priority set to undecided
- Status changed from new to pending