Stupid Question, Paragraphs?

Discussion in 'HTML & Website Design' started by gobbly2100, Aug 28, 2007.

  1. #1
    When I make paragraphs I swear that they are supposed to create natural breaks?

    Look at the content on this page: Diabetes Charity

    I have made it into paragraphs but why is it all bunched together?

    I really thought it just put spaces between the naturally.
     
    gobbly2100, Aug 28, 2007 IP
  2. NineDesign

    NineDesign Peon

    Messages:
    237
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Just add a margin to the bottom of it in the stylesheet.

    p { margin-bottom:1.75em; }

    Changing the line-height slightly can also increase overall readability.
     
    NineDesign, Aug 28, 2007 IP
  3. Meener

    Meener Banned

    Messages:
    2,905
    Likes Received:
    166
    Best Answers:
    0
    Trophy Points:
    0
    #3
    or just use

    <p> Your Text Here </p>
    <p> Your Text Here </p>
    Code (markup):
     
    Meener, Aug 28, 2007 IP
  4. gobbly2100

    gobbly2100 Banned

    Messages:
    906
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Oh thanks, I really thought it was standard HTML but CSS is not a problem.

    So it is not standard HTML then right?

    Thanks again!
     
    gobbly2100, Aug 28, 2007 IP
  5. Meener

    Meener Banned

    Messages:
    2,905
    Likes Received:
    166
    Best Answers:
    0
    Trophy Points:
    0
    #5
    Mine is HTML, NineDesign is a CSS code.
     
    Meener, Aug 28, 2007 IP
  6. RequiemStudio

    RequiemStudio Peon

    Messages:
    183
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #6
    This bit of code is removing all the browser's default margins:

    
    * {
    	margin: 0px;
    	font-family: MS Sans Serif4, Geneva, sans-serif;
    }
    
    Code (markup):
    So inserting a bit about padding into the CSS as described above or removing that * style should help normalize things a bit.

    You could also put the paragraphs into divs and control the padding through those styles.
     
    RequiemStudio, Aug 28, 2007 IP
  7. Dan Schulz

    Dan Schulz Peon

    Messages:
    6,032
    Likes Received:
    436
    Best Answers:
    0
    Trophy Points:
    0
    #7
    The universal selector should be used only for setting the margins and padding to zero. Font declarations should be put on the body, headings and those elements that require them when a different font family, size or line-height is needed to over-ride the defaults placed on the body or headings.

    I also strongly suggest setting the top and bottom margins on your paragraphs to be equal to half the current font size. 0.5em should be sufficient for this purpose. Then apply left and right padding to the paragraphs as needed.

    
    p {
        margin: 0.5em 0;
        padding: 0 1em;
    }
    
    Code (markup):
     
    Dan Schulz, Aug 29, 2007 IP