我正在使用 CKEditor 作为默认编辑器,我想为插件集成 TinyMCE 编辑器。这是我的代码:
function tiny_page() {
add_options_page(‘tiny’, ‘tiny’, ‘manage_options’, __FILE__, ‘tiny_form’);
}
add_action(‘admin_menu’, ‘tiny_page’);
/* load the tiny editor*/
function editor_admin_init() {
wp_enqueue_script(‘word-count’);
wp_enqueue_script(‘post’);
wp_enqueue_script(‘editor’);
wp_enqueue_script(‘media-upload’);
}
function editor_admin_head() {
wp_tiny_mce();
}
add_action(‘admin_init’, ‘editor_admin_init’);
add_action(‘admin_head’, ‘editor_admin_head’);
/* output the plugin page*/
function tiny_form() {
$args = array(“textarea_rows” => 5, “textarea_name” => “editor_content_1?);
wp_editor(“My editor content”, “my_editor_1?, $args);
}
问题是输出插件编辑器是 CKEditor 而不是那个小...</p>
有任何想法吗?