wp_editor on front end – JavaScripts not included

note that wp_editor will echo to output, not put it in a variable.
If you want to put it in a variable, just do

ob_start();
wp_editor($content, 'textarea_rich', $args);
$html = ob_get_contents();
ob_end_clean();

and you have what you need in $html.
You can also see https://plugins.svn.wordpress.org/indypress/tags/1.0/indypress/form_inputs/tinymce.php for a working implementation.

Another issue I noted is some problem is with w3-total cache minifying (actually, I had those issue with wp_tiny_mce, the function used in wp <= 3.2; I have not checked if it is buggy in wp_editor, too)

Leave a Comment