Reputation: 355
When I try to open the TinyMCE editor within a dialog box popup and click on "Insert link", the dialog box popup appears for "Insert link" but I am unable to write in the text field for "Insert link".
As far I know, the problem has to do with a dialog box open in another dialog box. Has anyone found a way around it?
Upvotes: 8
Views: 4231
Reputation: 111
i got another trick to solve that.. thanks to tyemmcee, see bug: http://www.tinymce.com/develop/bugtracker_view.php?id=5917
$.widget("ui.dialog", $.ui.dialog, {
_allowInteraction: function(event) {
return !!$(event.target).closest(".mce-container").length || this._super( event );
}
});
see tinymce fiddle: http://fiddle.tinymce.com/lpdaab/2
Upvotes: 1
Reputation: 355
I found the answer :)
$(document).on('focusin', function(e) {
if ($(e.target).closest(".mce-window").length) {
e.stopImmediatePropagation();
}
});
just paste the above code and focus will bbe automatically on last dialog box of TinyMCE.
Upvotes: 10