开发者

I can't use setContent in TinyMCE in full screen mode

开发者 https://www.devze.com 2023-02-01 05:33 出处:网络
While TinyMCE in full screen mode i cant set content inside tinymce I can set content while normally using TinyMCE but once in full screen mode I can\'t set content in TinyMCE.

While TinyMCE in full screen mode i cant set content inside tinymce

I can set content while normally using TinyMCE but once in full screen mode I can't set content in TinyMCE.

I tried:

tinyMCE.getInstanceById("textarea_id").setContent('this is a sample content');
tinyMCE.get('textarea_id').setContent('this is a sample content');

I read inside fullscreen plugin they used some thing like this:

fullscreenEditor.setContent

To fetch content

I need to know how to check TinyMCE in fullscreen or not and how to 开发者_运维问答set content inside TinyMCE in fullscreen mode


You need to adress the tinymce instance differently:

var new_content = "xyz";
tinymce.get('mce_fullscreen').setContent(new_content);
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号