Ticket #12550 (closed bug: fixed)
jQuery Ajax cache=false doesn't always work
|Reported by:||k@…||Owned by:||jaubourg|
When sending an ajax request with the "cache" option set to "false" then sometimes the request is still answered from the browser cache. The reason is that fast machines and fast browsers (like Chrome) are able to send multiple Ajax requests in the same millisecond. jQuery only adds the current timestamp to the URL, looks like this is no longer enough.
This page demonstrates the problem:
Keep reloading the page on a fast machine and you will sometimes get a red "DUPLICATE" warning instead of a green "OK" indicating a timestamp which was already used for a previous request. On my machine this happens on every 3rd reload or so.
I recommend adding another value to the timestamp to prevent this problem. Maybe a static counter? That's how we workaround the problem currently.
- Priority changed from undecided to low
- Status changed from new to open
- Component changed from unfiled to ajax
- Milestone changed from None to 1.9
- Owner set to jaubourg
- Status changed from open to assigned