I am using the Blueimp jQuery-File-Upload plugin (basic version) and I have a problem. The first file download works as expected, but when I want to send another file, it does not work.
fileinput.fileupload({ dataType: 'json', done: function (e, data) { $.each(data.result.files, function (index, file) { //do stuff with files }); } }).bind('fileuploadadd', function (e, data) { data.context = $('<p/>').text('Uploading...').appendTo(document.body); data.submit(); });
EDIT:
Ok, I know what causes the problem. But I do not know how to fix it. I used the fileupload plugin in the input, which set the display to none. I launch it with another button that uses the click () / trigger ('click') method for hidden input. the first trigger works fine, but the second starts the file selection dialog. After the selection, nothing happens. When I use the input field directly, it works as it should. How to overcome this problem?
jquery jquery-file-upload blueimp
Michał Leszczyński
source share