How to toggle browser_spellcheck dynamically in tinymce

我怕爱的太早我们不能终老 提交于 2021-02-11 13:38:21

问题


I've a custom toolbar button, which is used to toggle the browser's spell check. I've used

browser_spellcheck : true 

in the initialization. Now if we press button, then i need to 'off' the spell check.

So, how can we set browser_spellcheck to false dynamically?


回答1:


You cannot change the init settings of TinyMCE dynamically - it simply does not allow that to happen. If you need to change a setting like this you would need to use the remove() and init() APIs to reload the editor with new settings.



来源:https://stackoverflow.com/questions/51320654/how-to-toggle-browser-spellcheck-dynamically-in-tinymce

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!