I'm trying to get the size of a file from a file-input control. To do this I'm using jquery:
function init() {
$("#cphInhalt_cphInhalt_file0").bind("change", function() {
handleFileSelect(this);
});
}
function handleFileSelect(e) {
if (e.files[0].size + totalFileSize > 3000000) {
addNewUpload(e);
$(e).remove();
if (getCookie("language") == "German") {
alert("Die gesamte Dateigröße wurde überschritten");
} else {
alert("The total file size has been exceeded");
}
return;
}
In any browser this works fine, except of Internet explorer ( using version 11) , but as I think it should support the File Api right? It says e.files is undefinied