I am uploading an image in cropper container with the help of jquery. whenever I try to upload image on container, It does not refresh image source with base64 string generated at runtime in "cropper.js". So I wrote a function to generate base64 string in my controller and assigned it to some other image tag which is not being used by cropper, It works fine for that but It is not working for image container in cropper.
please let me know how to refresh the source.
Thanks.
Restart the cropper or call the replace method to change image src.
How do I call the replace method?
hi,
same problem with version 2.3.4;
i have used also
.cropper('destroy').cropper('replace', new_image)
but not working, the image on cropper-canvas is always old
have this problem only with base64 images, when use file image working without problems.
Thanks.
Most helpful comment
hi,
same problem with version 2.3.4;
i have used also
.cropper('destroy').cropper('replace', new_image)
but not working, the image on cropper-canvas is always old
have this problem only with base64 images, when use file image working without problems.
Thanks.