On 9/27/2011 12:46 PM, Robert wrote:
Local Storage.
Tnx! That was what I am looking for.
Just an additional question: in the scripts I viewed, I only saw
GM_get/setValue. Is there an advantage of using it compared to local
storage?
With other words: does it make sense to keep using GM_get/setValue?
Tnx,
Robert
If your application needs to work across multiple pages within the same
domain, local storage lets the code be split up into smaller scripts, so
that each one only needs to operate on a specific page. Using GM Prefs,
you have to create one mega-script, detect what page you're actually on,
and then only process the code for that page.
The downside is that local storage is specific to a domain, so it won't
work if the script has to access multiple domains. In that case, you
have to go the GM Prefs mega-script route. And as someone mentioned, it
can be harder to debug, since you can't easily look at or tweak the
data, like you can with GM Prefs.
--
You received this message because you are subscribed to the Google Groups
"greasemonkey-users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/greasemonkey-users?hl=en.