Reputation: 9645
How to cache html file forever or while ?version=1... is not added via $.get request?
I'm trying jQuery templating features, and want my templates to be cached all the time, until i'll change them.
I want to avoid unwanted requests to the server.
Upvotes: 0
Views: 620
Reputation: 1038810
You could set the cache: true
option when performing your AJAX request to cache the response in the browser. For more effective caching you could also set the proper cache HTTP headers on the server.
Upvotes: 1