0

What is the best way to store data to a local network drive, so that my Greasemonkey / Tampermonkey script can be used by everyone at my office?

And if its possible, i would like to be able to do this in Jquery.

I do not have a webserver running at my office either, only network drive that is accessible for everyone.

Can i for example store variables and data as .txt or to a SQLite database? or any other ways?

By network drive i mean, ie: "//hostname/sharename" or "N:/foldername"

Not sure if this is something i can use, but i guess not, since it seems to only give access to a sandboxed area i think: http://www.html5rocks.com/en/tutorials/file/filesystem/

patchie
  • 615
  • 1
  • 9
  • 21
  • Duplicate of [Save File using Greasemonkey](http://stackoverflow.com/questions/2951149/save-file-using-greasemonkey), and [Storing into file using JavaScript/GreaseMonkey](http://stackoverflow.com/q/6392103/331508), and others. – Brock Adams Oct 10 '13 at 06:58
  • Chrome, userscript file IO is sandboxed. Your web drive might have an optional web interface. If not, you must set up a local server or use Google doc/drive, or similar service on the web. – Brock Adams Oct 10 '13 at 07:03

2 Answers2

1

I guess you could use a WebDAV client for javascript, to edit stuff on the "network drive", maybe this will work? https://github.com/sara-nl/js-webdav-client

Nimantha
  • 6,405
  • 6
  • 28
  • 69
hanshenrik
  • 19,904
  • 4
  • 43
  • 89
0

I don't think you can do the way you want, but you can use for example pastebin.com to store data and then retrieve it by the script from time to time.

Consider reading How to paste text in Pastebin using JavaScript
This question is "how to paste", but the answer shows "how to read" too.

The problem with Pastebin is that it stops working when is under heavy load.

Community
  • 1
  • 1
w35l3y
  • 8,613
  • 3
  • 39
  • 51