0

I want to use the values of one page in another page using cache. Can any one suggest me how to use cache using jQuery?

After searching on several sites, I found this link : http://markdaggett.com/blog/2012/03/28/client-side-request-caching-with-javascript/. It uses a $.Cache.add(key,value); method.

When I used this in my aspx page it is throwing an error. Do I need to add any files to achieve cache?

2 Answers 2

1

If you want to store a value in one web page that you can retrieve in another page (on the same domain), you can either store it in a cookie or in local storage.

Browsers cache whole web resources (pages, images, scripts, etc...) not individual pieces of data.

Sign up to request clarification or add additional context in comments.

Comments

0

+1 for using the local-storage.

here is a nice little plugin for using the localStorage with jQuery (including docs): http://upstatement.com/blog/2012/01/jquery-local-storage-done-right-and-easy/

this plugin uses cookies as a fallback for browsers which do not support the localStorage-feature

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.