• Hi everyone,

    I’m working on a page, here someone could post his articles with WYSIWYG, and I want to call the WP’s default one. But I could not figure it out in the public pages. Because I only found the methods to integrate it in the admin panel:

    add_filter('admin_head','zd_multilang_tinymce');
    function zd_multilang_tinymce() {
    	wp_admin_css('thickbox');
    	wp_print_scripts('jquery-ui-core');
    	wp_print_scripts('jquery-ui-tabs');
    	wp_print_scripts('post');
    	wp_print_scripts('editor');
    	add_thickbox();
    	wp_print_scripts('media-upload');
    	if (function_exists('wp_tiny_mce')) wp_tiny_mce();
    // use the if condition because this function doesn't exist in version prior to 2.7
    }

    But I want to call the tinyMCE editor in a public page.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter zbq

    (@zbq)

    I think I have used the incorrect hook, then I changed it as following:

    add_filter('wp_head','zd_multilang_tinymce');
    function zd_multilang_tinymce() {
    	wp_admin_css('thickbox');
    	wp_print_scripts('jquery-ui-core');
    	wp_print_scripts('jquery-ui-tabs');
    	wp_print_scripts('post');
    	wp_print_scripts('editor');
    	add_thickbox();
    	wp_print_scripts('media-upload');
    	if (function_exists('wp_tiny_mce')) wp_tiny_mce();
    // use the if condition because this function doesn't exist in version prior to 2.7
    }

    But it still not work, I found the css file has been invoked, but the editor was not romanced, it was still a normal textarea.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘How to integrate the tinymce editor in the public pages?’ is closed to new replies.