WordPress.org

Support

Support » How-To and Troubleshooting » How to add extra space between some (not all) paragraphs

How to add extra space between some (not all) paragraphs

  • I need to add extra space before and after certain paragraphs to make them stand out. I don’t want to add padding or margins in the css because it’s just for occassional situations. I’ve tried inserting the code for empty paragraphs, blockquotes and lists items but nothing worked. I suppose I could create a class just for these times, but it seems like there must be something easier that I’m missing.

Viewing 9 replies - 1 through 9 (of 9 total)
  • how bout lots of
    <br /><br /><br /><br /><br /><br /><br /><br /><br />

    but I still think, classifying is the cleanest solution
    <p class="special">a paragraph</p>

    < p >
    < /p >

    should work.

    Or it does not have to work 🙂 I read somewhere about collapsing margin, that the margin of that blank paragraph collapse with the previous box’s margin, that it looks like it does not have margins. Not sure though.

    well that makes sense, check your margin parameters. 🙂

    The best I’ve ever figured is
    <p>&nbsp;</p>

    That’s [open paragraph] [forced space] [close paragraph]
    If you don’t include the space, it won’t work.

    Unless I’m missing something, none of the things that work on html pages â€? like
    or â€? work when added to a wp post or page. So it’s looking like the only way is a special class, which isn’t bad for me, but I’m setting up a lot wp sites for clients and would prefer solutions that didn’t involve special tags.

    Then you’ll have to sacrifice and make exceptions for hacks:

    Use <p>&nbsp;</p> as mentioned above. The <br /> tag is for use inside of things like <p> tags to force single line breaks.

    Thanks, I was using p tags but without the &bsp.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘How to add extra space between some (not all) paragraphs’ is closed to new replies.
Skip to toolbar