Only chrome 22 and later supports uploading relative folder names at dragging and dropping folders on browser upload (html5).
When i am trying to upload multiple files with chrome drag&drop folder support, i am experiencing some kind of limitation. And i couldn't find any way to change or disable this limitation.
When you just select 1000 files and drop to uploader it does work and adds those files to upload list after waiting for a while for processing. That is ok.
When you select a folder including 1000 files inside and drop to uploader, then uploader just adds random 100 files in that folder.
When you create 110 folders, then include 1 file each in folders, then uploader adds just 100 files leaving 10 folders out.
It seems, chrome file/folder upload mechanism somehow limits maximum items in any folder while recursively crawling files & folders. And limitation number is 100.
I couldn't find any related documentation, and i am desperately in need for raising that limit to 1000 file/folder each at minimum or no limit.
Thank you all already.
After searching relevant documentation for 2 days, i could find an answer in following url.
https://developer.mozilla.org/en-US/docs/Web/API/DirectoryReader#readEntries
And i could able to fix blueimp uploader.
in jquery.fileupload.js
Find:
} else if (entry.isDirectory) {
dirReader = entry.createReader();
dirReader.readEntries(function (entries) {
that._handleFileTreeEntries(
entries,
path + entry.name + '/'
).done(function (files) {
dfd.resolve(files);
}).fail(errorHandler);
}, errorHandler);
} else {
Replace:
} else if (entry.isDirectory) {
dirReader = entry.createReader();
var entries = [];
var readEntries = function () {
dirReader.readEntries(function (results /* entries */) {
if (results.length) {
entries = entries.concat(Array.prototype.slice.call(results || [], 0));
readEntries();
} else {
that._handleFileTreeEntries(
entries,
path + entry.name + '/'
).done(function (files) {
dfd.resolve(files);
}).fail(errorHandler);
}
}, errorHandler);
};
readEntries();
} else {
I hope that helps.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With