WordPress.org

Ready to get started?Download WordPress

Forums

Blank lines impossible? (14 posts)

  1. t40fjk230
    Member
    Posted 4 years ago #

    Hi,

    it seems that I can't insert blank lines (more than 1) into my post. They're removed when I submit the post.

    But I need some whitespace in my post (http://blog.itsth.com/2010/06/24/replybutler-4-03/), otherwise the bullet-list would be indented by the picture which wouldn't look good.

    I resorted to using white dot characters, but perhaps there could be a better solution in future versions?

    Thanks,

    Thomas

  2. mrmist
    Forum Janitor
    Posted 4 years ago #

    If you use the html editor you can add blank lines with <p>&nbsp;</p> I believe. Or you could use a disabled wpautop plugin to turn off all the WordPress automatic filtering for content layout. Or you could use CSS to properly style your paragraphs and images, which is (I think) the reasoning why the blank lines are removed in the first place, as the represent bad coding practice.

  3. t40fjk230
    Member
    Posted 4 years ago #

    Hi mrmist,

    Thanks for your quick answer. Yes, there are quite a number of possible workarounds for this.

    I just wanted to point out that this problem exists. Perhaps not only for me. And perhaps this is a chance to make WordPress even better. ;-)

    Thanks,

    Thomas

  4. Dirk Sohler
    Member
    Posted 4 years ago #

    I don’t think that it is a real problem. It’s more like very unusual to put more than one “empty line” into a blog post (i fact that aren’t empty lines, thats paragraph margins).

    It would be WAAAY more valid (speaking of logical validity *g*) if you switch to HTML editing and manually add a margin to the <p> tag of the paragraph you want to have more space below/above.

  5. I usually toss in a <div style="clear:both;"></div> or a <br style="clear:both;" /> when I want to break that sort of image wrap issue. The clear basically kicks you down to below the image.

  6. mrmist
    Forum Janitor
    Posted 4 years ago #

    It's not seen as a problem by the development team, it's seen as working as intended....

  7. Samuel Wood (Otto)
    Tech Ninja
    Posted 4 years ago #

    Multiple blank lines are intentionally removed. If you want to add vertical whitespace, you should use CSS styling to add that sort of space into your theme properly.

  8. t40fjk230
    Member
    Posted 4 years ago #

    @Ipstenu: Brilliant! <div style="clear:both;"></div> works much better than my blank lines. Thank you!

    I think it might be useful to other users, too, to have a simple solution for this. Like a button to insert this "clear:both" break.

  9. petedutcher
    Member
    Posted 4 years ago #

    It might be intended, but it's a really bad move. Unfortunately, there are people that us WordPress that are not experienced enough to "add code" or "CSS". I have clients I design templates for.

    Do you really expect me to tell them to add code? It doesn't work that way in the commercial market.

  10. Samuel Wood (Otto)
    Tech Ninja
    Posted 4 years ago #

    Do you really expect me to tell them to add code? It doesn't work that way in the commercial market.

    No, I expect you to design your client's theme in a way that doesn't require them to add code.

  11. Or use a plugin like this: http://wordpress.org/extend/plugins/post-editor-buttons/

    And customize the buttons for them so they have an easy way to add blank lines.

    Heck. Make a shortcode [break] that plunks in that code.

  12. David Tierney
    Member
    Posted 4 years ago #

    Unfortunately, that plugin only works for the html editor, not the visual editor. I found this post because I have a similar need, (that I outlined here: http://wordpress.org/support/topic/417762.

  13. David Tierney
    Member
    Posted 4 years ago #

    Here is a plugin that gives more control on the Tinymice, including a button that allows you to insert a line break that will stick.

    http://wordpress.org/extend/plugins/tinymce-advanced/

  14. neworld
    Member
    Posted 4 years ago #

    Thanks for the link to that plugin, Big dave. I too wanted a way to insert an extra line break. The plugin worked perfectly.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.