Hey,
I am trying to prevent users from uploading exe's || zip's, I am calling the below script on the select event .
this.onSelect = function(e) {
$.each(e.files, function(index, value) {
if(value.extension=='.zip' || value.extension=='.exe') {
e.preventDefault();
return;
}
}
}
This prevents the file from appearing in the file list but if I do a submit the zip's are going to the server. I could see input type 'file' elements are getting created even though filelist is not displaying the same. Whats the way around for this
I am trying to prevent users from uploading exe's || zip's, I am calling the below script on the select event .
this.onSelect = function(e) {
$.each(e.files, function(index, value) {
if(value.extension=='.zip' || value.extension=='.exe') {
e.preventDefault();
return;
}
}
}
This prevents the file from appearing in the file list but if I do a submit the zip's are going to the server. I could see input type 'file' elements are getting created even though filelist is not displaying the same. Whats the way around for this