Angular and Bluimp jQuery-file-upload: parseMetaData error
Asked Answered
L

2

5

I'm unable to upload files because of the following error at jquery.fileupload-image.js:268

Uncaught TypeError: Cannot read property 'parseMetaData' of undefined

I'm including the following files:

ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.js
ajax.googleapis.com/ajax/libs/jqueryui/1.11.1/jquery-ui.js
ajax.googleapis.com/ajax/libs/angularjs/1.2.22/angular.js
maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.js
cdnjs.cloudflare.com/ajax/libs/blueimp-file-upload/9.5.7/jquery.iframe-transport.js
cdnjs.cloudflare.com/ajax/libs/blueimp-file-upload/9.5.7/jquery.fileupload.js
cdnjs.cloudflare.com/ajax/libs/blueimp-file-upload/9.5.7/jquery.fileupload-process.js
cdnjs.cloudflare.com/ajax/libs/blueimp-file-upload/9.5.7/jquery.fileupload-image.js
cdnjs.cloudflare.com/ajax/libs/blueimp-file-upload/9.5.7/jquery.fileupload-audio.js
cdnjs.cloudflare.com/ajax/libs/blueimp-file-upload/9.5.7/jquery.fileupload-video.js
cdnjs.cloudflare.com/ajax/libs/blueimp-file-upload/9.5.7/jquery.fileupload-validate.js
cdnjs.cloudflare.com/ajax/libs/blueimp-file-upload/9.5.7/jquery.fileupload-angular.js

Here is my HTML:

<form data-file-upload="options">
    <span class="btn btn-success fileinput-button">
        <span>Add files...</span>
        <input type="file">
    </span>

    <button type="button" class="btn btn-primary start" data-ng-click="submit()">
        <span>Start upload</span>
    </button>
</form>

And here's my Angular:

$scope.options =
    url: 'some.endpoint'
Langan answered 18/9, 2014 at 22:50 Comment(0)
I
18

I just had the same error.

The link to the file Javascript-Load-Image/js/load-image.min.js has changed on github and is know : Javascript-Load-Image/js/load-image.all.min.js

By changing that it worked with me. :)

Thoma

Iliad answered 19/9, 2014 at 4:28 Comment(0)
O
4

I had this problem too. Please note that load-image.all.min.js needs to be included before the jquery.fileupload-image.js.

That was the problem here.

Octavus answered 9/3, 2015 at 13:46 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.