I'm writing some tests trying to get the blueimp jquery-fileupload plugin working with angularjs.
Here is what I wrote, trying to keep it as simple as I could :
[controller.js]
app.controller('myAppController', function ($scope, uploadHandlerUrl) {
$scope.options = {
url: uploadHandlerUrl,
add: function(e,data) {
angular.element('#submit').click(function() {
data.submit();
});
},
done: function(e, data) {
console.log('done', data);
},
progress: function(e,data) {
console.log('progressing', data)
}
};
});;
[html]
<form id="fileupload" method="POST" enctype="multipart/form-data" data-fileupload="options">
<input type="file" name="files[]" multiple="">
<button id="submit">Submit</button>
</form>
You can also see a running instance here.
The problem is, every data object that is returned by the fileupload plugin seems to tell me that eveything went fine, but no files are actually uploaded on the server (the files should be uploaded here).
It may be caused by some configuration issue on my server, but I've absolutely no idea in which direction I should search. I'm using blueimp native uploadHandler.php on the server-side