setting TinyMCE options in TinyMCEComments (2 posts)

  1. joneiseman
    Posted 4 years ago #

    Is there some way to set TinyMCE options in the TinyMCEComments plugin?
    I added the following in the functions.php for my theme:

    function change_mce_options( $init ) {
     $init['extended_valid_elements'] = 'span[!class]';
     return $init;
    add_filter('tiny_mce_before_init', 'change_mce_options');

    This change to the TinyMCE options works when using TinyMCE to edit WordPress articles but it doesn't work when adding comments using TinyMCE through the TiunyMCEComments plugin.


  2. joneiseman
    Posted 4 years ago #

    I figured out the answer to my own question. I thought I'd post it here in case anyone else needs an answer to this. The MCE init options are in the $initArray inside the function mcecomment_getInitJS in the file tinyMCEComments.php. I just added the following to the array:

    'extended_valid_elements' => "span[!class]",

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • TinyMCEComments
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic