I have a custom plugin for TinyMCE that adds a custom button to the toolbar to upload images using AJAX.
This is my code:
tinymce.activeEditor.execCommand('mceInsertContent', false, '<img src="'+response.url+'" />');
The problem is that after the image is added to the editor the editor height doesn't update. I must write anything or use Ctrl + A to update the height of the editor.
Screenshot: https://i.stack.imgur.com/dNveG.png
My TinyMCE settings:
'height' => 150,
'autoresize_min_height' => 150,