Is it possible to read the contents of an uploaded file (through <form><input type="file">
) from inside javascript with no backend? I suppose it's possible with HTML5, but what about HTML4?
views:
38answers:
3The security model will not let you unless you change the security to allow this. http://www.mozilla.org/projects/security/components/signed-scripts.html Can you elaborate on what you want to do?
I read the question as "How do I grab the contents from a file chosen using a file upload field and process it on the client without involving a backend/webserver". I am thinking UniversalBrowserRead access for FF and HTA filesystem for IE for example
You can read (not upload - well, you can upload too, but that's like sending fan-mail to Edgar Allen Poe; nothing stops you but he won't be able to read it) from files if your script runs in a very trusted context.
If anyone on your network is browsing the web in a browser set to give that much trust, disconnect their machine from the network first, make their settings tighter second.