Try looking in wp-includes/js/timymce
I found only this:
if (settings.verify_html === false)
settings.valid_elements = '*[*]';
But not sure if this is right.
Also that there was a tinymce bug in one or several version that didn’t recognize this *[*] – is that true?
Also that there was a tinymce bug in one or several version that didn’t recognize this *[*] – is that true?
Sorry – I’ve not heard anything about that.
esmi have you working with custom styles in tinymce editor? I’m looking for solution that will add <i> tag to each <li> element.
I try this:
function custom_mce_before_init_insert_formats($init_array) {
$style_formats = array(
array(
'title' => 'arrow',
'inline' => 'i',
'classes' => 'icon',
'wrapper' => false,
'exact' => true
)
);
$init_array['style_formats'] = json_encode($style_formats);
return $init_array;
}
add_filter('tiny_mce_before_init', 'custom_mce_before_init_insert_formats');
but this add <i>as wrapper of content of <li> element so the result is:
<li><i class="icon">item 1</i></li>
but I want this:
<li><i class="icon"></i> item 1</li>
Thank you
[Please post all markup tags between backticks or use the code button. Post (painfully) re-constructed after it broke the forum’s topic display.]
I’ve not really worked with tinymce’s CSS but why are you trying to add an <i> tag? Is this to markup text in an “alternate voice”?
OK,
hopefully I have found solution – I must create custom shortcode plugin. This plugin is generate <i> tag into <li> as I want. There is just need to replace some string and loop over every<li> tag.
Thanks anyway