WordPress.org

Ready to get started?Download WordPress

Forums

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

  1. msky
    Member
    Posted 9 years ago #

    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.

  2. Joshua Sigar
    Member
    Posted 9 years ago #

    how bout lots of
    <br /><br /><br /><br /><br /><br /><br /><br /><br />

  3. Joshua Sigar
    Member
    Posted 9 years ago #

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

  4. Lori
    Member
    Posted 9 years ago #

    < p >
    < /p >

    should work.

  5. Joshua Sigar
    Member
    Posted 9 years ago #

    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.

  6. Lori
    Member
    Posted 9 years ago #

    well that makes sense, check your margin parameters. :)

  7. gadlen
    Member
    Posted 9 years ago #

    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.

  8. msky
    Member
    Posted 9 years ago #

    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.

  9. Kiddeath91
    Member
    Posted 9 years ago #

    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.

  10. msky
    Member
    Posted 9 years ago #

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

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.