When i am trying to upload image via ajax in local, browser show the error too much recursion. so i couldn't test that in locally, but its works in production on heroku
$('#fileupload_pers').fileupload({
url: '/create_img_prs',
add: function (e, data) {
$('#upload_pers').html('<p class="upl label label-
success">Uploading....please wait</p>');
data.submit();
},
success: function (r) {
//$('#upload').remove();
$('#upload_pers').empty();
$('#upload_pers').html('<p class="upl label label-success">Successfully
Uploaded Image</p>') ;
$('#id_poster_pers').attr('value',r["id"]);
$('#upload_pers').fadeOut(6000);
}
});
The error 'too much recursion' can be caused by (accidently) including jquery.fileupload.js twice.
https://github.com/blueimp/jQuery-File-Upload/issues/2814
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