Reputation: 799
I have been using Cloudinary to upload images via their unsigned API. But a lot of the response text is inaccessible. I primarily need the file addition attached to the uploaded image name i.e.
myImage_xJyk.jpg.
I tried reparsing the json, looping and trying to access the object keys. How can I get the response data from an unsigned upload.
$('.upload_form').append($.cloudinary.unsigned_upload_tag("abcdefg", {
cloud_name: 'sample',
api_key: '12345678910'
},{
multiple: true,
})).bind('cloudinaryprogress', function(e, data) {
console.log(data.result.public_id);
});
Upvotes: 0
Views: 77
Reputation: 1931
The cloudinaryprogress
only is relevant to the process of the upload itself, e.g., for indication of the upload progress. It doesn't know the public ID of the uploaded image yet. You'll need to bind to the cloudinarydone
event instead to get the public ID of the upload image.
Upvotes: 1