[resolved] Avoid the WYSIWYG editor replaces b and i tags with strong and em (2 posts)

  1. Andrés Sanhueza
    Posted 4 years ago #

    In HTML5, the b and i tags have an independient semantinc from strong and em tags (Although they look the same and the standard is not yet finished, but still). I actually have some usage for b and i, yet when I try to do so, the WYSIWYG editor replaces them with strong and em respectively. Similar thing happens with the u tag which gets replaced by a styled span. There may be other tags affected. There's some way to avoid that?

  2. Andrés Sanhueza
    Posted 4 years ago #

    I solved it by reading the Codex and some TinyMCE documentation. Something like this has to be added to a plugin or theme function:

    function myformatTinyMCE($in)
     return $in;
    add_filter('tiny_mce_before_init', 'myformatTinyMCE' );

Topic Closed

This topic has been closed to new replies.

About this Topic