0

I am trying to cache the jQuery Ajax response. The response headers are as below
But the data is not getting cache each time it is requesting back to server.

enter image description here
I have gone though the link
1. Caching a jquery ajax response in javascript/browser and few other my jquery call is like below

 $.ajax({
                url: "xxx",
                type: "POST",
                data: { 'xxx':'XXX'},
                asyn: false,
                contentType: "application/json; charset=utf-8",
                dataType: "json",
                success: function (data)...

but still no luck.

शेखर
  • 17,412
  • 13
  • 61
  • 117

1 Answers1

1

It looks like POST responses are not cached. From this:

The parameter is not needed for other types of requests, except in IE8 when a POST is made to a URL that has already been requested by a GET.

Also, see this:

Caching a jquery ajax response in javascript/browser

Frank Fajardo
  • 7,034
  • 1
  • 29
  • 47