How do I use jQuery to add the TinyMCE WYSIWYG editor to a textarea?
I would just use the WordPress JavaScript API for TinyMCE — wp.editor. The steps in brief: PHP: Enqueue the editor scripts (and styles) via wp_enqueue_editor(). JS: Call wp.editor.initialize() from your script. And do take note of this: (the “this function” refers to wp.editor.initialize) If this function does nothing, please make sure that wp.editor.getDefaultSettings is a … Read more