Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

IE9 fakes 304 after receiving ETag

I've got a problem with AJAX & Internet Explorer 9: it stops polling our server after receiving response to initial etagged GET.

It pretends to issue requests with response like "Response HTTP/1.1 304 Not Modified, Status 200 OK" (yes, two different status codes in one response) and same ETag (which should change with time) but none of them actually appears in server logs.

This problem appears only in IE, same code works just fine in Chrome & FF.

Perhaps passing {cache: false} to jQuery.ajax() could help, but I'd like to know if there is a way to solve the problem on a server side.

There may be a mistake in our ETag usage.

Thank you!

like image 767
Alexander Avatar asked Apr 27 '12 16:04

Alexander


1 Answers

I suppose this article will be usefull for you: http://www.dashbay.com/2011/05/internet-explorer-caches-ajax/

The problem is in AJAX caching. You should forbid it anyway for necessary request.

like image 118
JuliaCesar Avatar answered Oct 14 '22 23:10

JuliaCesar