• Resolved wpu9000

    (@wpu9000)


    When I try to add code to the text/html editor it is lost when I switch to visual view.
    For example I tried to add: <br style=”clear:both;” />
    but it will not stay.
    I added it inside div’s
    <div> <br style=”clear:both;” /> </div> but it was cleared again when I switched to visual view, the div’s where left though.
    It is the same for <p> tags…

    https://www.ads-software.com/plugins/wp-edit/

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Josh

    (@josh401)

    WordPress includes many ‘behind the scenes’ functions which run whenever the editor is switched between views (text and visual); or whenever the content is saved/published.

    One such function is the wpautop() filter. This is the one that ‘automatically’ creates p tags. This may or may not be desired.

    What exactly are you wanting to accomplish?

    Thread Starter wpu9000

    (@wpu9000)

    Hello,
    I have been reading about the wpautop filter, so I understand now this is not really anything to do with WP Edit.
    What I really want is for whatever html I type into the text side of the editor to stay exactly as I have typed.
    I think I will try disabling wpautop for a while and see if that is better.

    thanks for pointing me in the right direction.

    Plugin Author Josh

    (@josh401)

    No worries.

    Instead of:
    <div> <br style="clear:both;" /> </div>
    You could try this:
    <div style="clear:both;margin-top:20px;"></div>
    Which would still clear the floats, and also add a margin-top.. replicating some line breaks.

    (Gonna mark this topic as ‘resolved’. Feel free to change back if necessary)

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘WP Edit not saving changes’ is closed to new replies.