New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TinyMCE 4 strips img tags with base64 #2
Comments
Actually this plugin automatically convert img to base64 |
Fixed thanks |
I created a TinyMCE bug report for this. Vote for it here: |
Actually, the solution for this is a tiny tweak to your TinyMCE configuration. See here: |
and you can use this in your tinymce 4 init script so your images are really saved as base64 (even pasted ones) paste_data_images: true,
images_upload_handler: function (blobInfo, success, failure) {
// no upload, just return the blobInfo.blob() as base64 data
success("data:" + blobInfo.blob().type + ";base64," + blobInfo.base64());
} PS: with this code you don't need to change mceInsertContent, it will work |
@xaviergonz , can you send pull request? or send us complete file with changes, we shall update it. Thanks |
How would I? The code needs to be added to the tinymce.init() function, not to your plugin itself. |
@xaviergonz ok thanks 👍 |
I did create a pull request based on the code I use, but it is quite a big pull request :) |
Thx xaviergonz! The images_upload_handler is working! |
@xaviergonz Thanks |
I'm still trying to figure out how to fix this myself, but the instructions should be updated once this is resolved.
The text was updated successfully, but these errors were encountered: