Paragraph spacing

  • Unknown's avatar

    I have the “Custom Design” upgrade.

    Is it possible to tighten the spacing between certain paragraphs? I don’t want to change the spacing between the majority of my paragraphs, but there are certain ones (which I usually indent) where I would like to significantly reduce the between-paragraph spacing.

    Is this possible?

    The blog I need help with is: (visible only to logged in users)

  • Unknown's avatar

    Hello there,

    I don’t have the CSS upgrade so I can’t try the following. But try this.

    1) In the paragraph that you want to have different spacing, in the HTML editor, add a class to it. Example

    <p class="shorter">Test Paragraph</p>

    2) In the CSS enter a new class definition and tweak it. Example:

    p.shorter {margin-bottom:0px;}

    That might work. You can also use margin-top; margin-left; margin-right.

    Let me know if it works. I’m curious too!

  • Unknown's avatar

    Thanks for the suggestion, Danny.

    I tried this and it appears that my current configuration will not accept paragraph style changes to the HTML.

    The CSS change you provided was accepted and still appears when I call it up, but the new HTML disappears when I call the page back into the text editor (in other words, I inserted the HTML you provided at the desired point, published, and when the change didn’t take effect, called up the HTML again and the new HTML was gone).

    Still appreciate the suggestion though, it was worth a shot. Will keep fiddling and post if anything works.

  • Unknown's avatar

    Hi there, the above will work, but you need to use the !important attribute on the margin declaration to force-override the original in this case, and I would also do away with the “p” at the beginning of the selector.

    .shorter {
        margin-bottom: 0 !important;
    }

    Also on margins and padding, for 0 (zero) you do not need to use the px and in fact sometimes it can cause issues with some older browsers.

  • Unknown's avatar

    Thanks Danny and sacredpath for taking the time to reply.

    With your help, I think I’ve figured this out — at least, I was able to adjust certain paragraphs the way I wanted by inserting “margin-bottom 0” into the p-style tag, as follows:

    <p style=”padding-left: 30px; margin-bottom: 0;”>

    The original HTML for a “normal” paragraph with my template is <p style=”padding-left: 30px;>

    And that appear to be all that’s required. This allows me to have normally spaced paragraphs, followed by indented paragraphs with no spacing that are visually “set apart” from the regular paragraphs, as appears on this page of my blog (note how the interview transcript now appears “single-spaced” compared to the rest — that’s the effect I was looking for):

    http://adverbkiller.com/2014/08/10/profanity/#more-132

    Thanks again for replying and all the best.

  • Unknown's avatar

    Great! I’m glad you got it working!

  • The topic ‘Paragraph spacing’ is closed to new replies.