Support » Fixing WordPress » WordPress deletes code when switching from CODE to VISUAL

  • I have some custom html hode in my post:

    <table style="float: left; margin-right: 15px;" border="0" cellspacing="0" cellpadding="0" width="210">
    <td width="210" background=""><a href="../wp-content/uploads/2011/03/51U7kKPpViL._SS500_-1.jpg"><img class="aligncenter" title="51U7kKPpViL._SS500_-1" src="../wp-content/uploads/2011/03/51U7kKPpViL._SS500_-1-208x300.jpg" alt="" width="208" height="300" /></a></td>

    However, when I switch from CODE to the VISUAL view, wordpress always deletes the <td width=”210″ background=”http://www….com/images/table.gif”> code

    What can I do that wordpress doesn’t delete this code?

Viewing 1 replies (of 1 total)
  • You really can’t.

    This is a known limitation of the TinyMCE editor which WP uses.

    You can’t switch between html and visual editor when inputting code, some (not all) code gets eaten

    stick to the html view on those posts is unfortunately the current solution

Viewing 1 replies (of 1 total)
  • The topic ‘WordPress deletes code when switching from CODE to VISUAL’ is closed to new replies.