Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm using Firefox 10.0 with Greasemonkey 0.9.15. I want to use a userscript, that requires access to local storage. I don't want local storage to be allowed globally.

Is there a way to achieve this goal without modifying userscript?

If userscript modification is necessary, what can I use as the replacement for local storage?

share|improve this question

The Greasemonkey equivalent of localStorage are the GM_getValue and GM_setValue functions. Just be aware that for example the contemporary Chrome implementation of userscripts doesn't support these (among other things) and if you want your userscripts to work cross-browser, you'll still have to write a fallback function using localStorage.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .