JavaScript - FileReader during pageload to get dataUri

Asked By anbu n on 07-Aug-14 10:50 PM
https://developer.mozilla.org/en-US/docs/Web/API/FileReader
http://blog.teamtreehouse.com/reading-files-using-the-html5-filereader-api

in above url, datauri - base64 string is taken during load event of filereader.

but i require datauri - base64 string normally , during page load
Robbe Morris replied to anbu n on 08-Aug-14 07:53 AM
Even with this FileReader API, a human must trigger the file read request for security purposes.  You can't do what you are asking for which is to trigger the upload of a file in the page load event without the human user taking action to trigger it.