Can someone tell me why WordPress re-formats my articles?

by timber
10 replies
  • WEB DESIGN
  • |
I have spent about 2 hours writing this article, it looks good with the formatting I had when I decided to transfer it to a post.

I put in all the pictures, all the blocking... everything looked great and as I wanted it before I posted it. But now, almost all the formatting is borked!

<br> and <p> are all but ignored, when I edit it back in the html view, it just jumps back to the borked version when I update it.

Anyone have any idea why it does this? Or more importantly, how to fix it? this is really ticking me off!

Here's the page:
http://theguitarreviews.com/learn-th...is-not-a-race/
#articles #html formatting #posting #reformats #wordpress #worpress
  • Profile picture of the author mrmagos
    The visual editor in WP tends to strip out extra tags like this. You can turn it off by going to Users > Your Profile and ticking the checkbox to disable it.
    {{ DiscussionBoard.errors[2440131].message }}
    • Profile picture of the author timber
      Originally Posted by mrmagos View Post

      The visual editor in WP tends to strip out extra tags like this. You can turn it off by going to Users > Your Profile and ticking the checkbox to disable it.

      what is the option in there? the only one I can find is:
      Disable the visual editor when writing.
      Signature

      {{ DiscussionBoard.errors[2440145].message }}
  • Profile picture of the author mrmagos
    That's the one - tick that and save. You'll then need to go back and fix your post again.
    {{ DiscussionBoard.errors[2440187].message }}
  • Profile picture of the author timber
    Hey, thanks for the advice...
    I tried as suggested, and made the change, but it's still not reflecting the changes made.
    I even went so far as to past the code into Dreamweaver, put the whole thing into a table the same size as the post area, and editited in there to how I liked it. Then copied that code, went back to wp, deleted the code in there, updated, then pasted the new code into it, and updated it again. Still the same problems.

    I'm thinking I'm just going to have to leave it be, I don't know why it keeps doing this, but I'm about ready to give up on it.

    could it be the theme? I've had to fight with this silly theme almost from day 1!
    Signature

    {{ DiscussionBoard.errors[2442134].message }}
  • Profile picture of the author LessThanWeb
    Start from start
    Delete the content, save it as empty page and then switch the editor to "HTML" and paste the text there. That way the HTML tags won't get all messed up. Just don't switch back to "Visual".

    Then go to your page, view source of the page and check if the HTML tags really are there and that they have not been converted as they are when you use "Visual".

    If you see HTML tags as you entered them, then its your theme but i really doubt that theme would mess up this.
    {{ DiscussionBoard.errors[2442146].message }}
  • Profile picture of the author bgmacaw
    WordPress filters content to make it more presentable. This, unfortunately, gets in your way if you want to post full HTML code in a post or page. As the others mentioned, you want to turn of the visual editor, however, this only gets rid of part of the problem.

    To get rid of WordPress changing your code entirely, you have to remove two filters.

    PHP Code:
    remove_filter ('the_content''wpautop'); 
    will prevent WordPress from adding in <p> and <br> tags.

    PHP Code:
    remove_filter('the_content''wptexturize'); 
    will stop "smart quotes" and some other modifications to your code.

    Add these two filters into your theme code, in PHP tags of course, above the start of the loop on post/page templates where you don't want them to work.
    {{ DiscussionBoard.errors[2442555].message }}
    • Profile picture of the author KathyK
      Originally Posted by bgmacaw View Post

      WordPress filters content to make it more presentable. This, unfortunately, gets in your way if you want to post full HTML code in a post or page. As the others mentioned, you want to turn of the visual editor, however, this only gets rid of part of the problem.

      To get rid of WordPress changing your code entirely, you have to remove two filters.

      PHP Code:
      remove_filter ('the_content''wpautop'); 
      will prevent WordPress from adding in <p> and <br> tags.

      PHP Code:
      remove_filter('the_content''wptexturize'); 
      will stop "smart quotes" and some other modifications to your code.

      Add these two filters into your theme code, in PHP tags of course, above the start of the loop on post/page templates where you don't want them to work.
      If you are using excerpts, you will also want

      PHP Code:
      remove_filter('the_excerpt''wpautop'); 
      and possibly
      PHP Code:
      remove_filter('the_excerpt''wptexturize'); 
      if you want to stop curly quotes and such.

      If your theme has a functions.php file, you can put them in there.
      Signature

      Cheers,
      Kathy

      {{ DiscussionBoard.errors[2444259].message }}
  • Profile picture of the author Istvan Horvath
    As one Winnipeger to the other

    Why do you need to edit your posts in "fancy" editors before using WP?

    What is it that you need and cannot be done in WP? (just askin'...)

    I looked at your page in the OP and whatever I see there can be done easily in WP.
    Signature

    {{ DiscussionBoard.errors[2442604].message }}
  • Profile picture of the author Abledragon
    I've used the Raw-HTML plugin for some time. It enables you to evade the WordPress HTML police whenever you want, without needing to switch off the Visual editor.

    I wrote a review of it here:

    http://www.wealthydragon.com/blog/20...ordpress-html/

    Cheers,

    Martin.
    Signature
    WealthyDragon - Earning My Living Online
    {{ DiscussionBoard.errors[2442936].message }}
  • Profile picture of the author acidophulus
    HELP- I am having same problem and spent months trying to figure this out. Is it my Flex Squeeze theme? I am not sure about how to do the technical stuff as mentioned in post of another person. The text is erratic and does what it wants after I made text red, bigger etc. It is not WSIWG at all. I installed tinymce. I don't know how to do settings though. I don't know if that interferes with default HTML. I simply want to make my sales page and have it look exactly like I type in visual editor. I don't know how to type in html editor if I can't see what page looks like as I type along.

    I have spent months trying to get assistance and hours and hours typing and retyping and getting nowhere. It seems it works and then it doesn't. I have almost lost my mind already.

    I am not a techno geek. Someone mentioned erasing all the h tags in code. I don't want to destroy theme unless it is already messed up. Is it my theme, is it wordpress, is it my computer, is it from a plugin?

    Here is one site that is a mess. attractwomenguide.com. I gave up, I can't waste more time but I want to finish my first ever affiliate site.

    Text randomly does what it wants after I spent hours making the page look half decent. Anyone have skype to do a screen share. Or easy to follow instructions that a kid could do it. I am trying to finish this and it is driving me crazy. Any recommendations for another theme that has built in squeeze page like flex squeeze and is as easy. Any theme templates for a mini-site you can recommend.

    Thanks so much to anyone who can help me. I am at my wits end and beyond. ANd everyone always says how easy wordpress is. It has been a nightmare for an un technical person like me.
    {{ DiscussionBoard.errors[2442969].message }}

Trending Topics