I've created one and would like to read the contents of this input before sending it to the server. I saw that I can do this using a filereader but the information I found was kind of confusing.
How can I do this reading?
The read would be from a txt file.
var file = document.getElementById("inputmarc");
var fr = new FileReader();
fr.readAsBinaryString(file.files[0]);
fr.onload = function(e) { alert(e); }
No HTML:
<input type="file" id="inputmarc">