• Resolved frenchkitty

    (@frenchkitty)


    Hello,
    this is a very silly question but could someone please enlighten me as to what i’m doing wrong when trying to add a line break between the main title and text below? http://www.frenchkit.com/
    I’ve tried <p></p>,
    </br>, even   but this adds a way too big a gap. Help anyone?
    Thanks a lot
    Samia

Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter frenchkitty

    (@frenchkitty)

    it got erased i wrote &nbsp
    Hope you can see it now.

    It’s good practice to never use <p> tags to add space between text. Since your doctype is declared as HTML5 you should use
    with no closing tag.

    If that doesn’t work you can add padding to your header tags that will let you better control the spacing.

    example:

    h1 {
    padding-bottom: 5px;
    }

    oh that’s funny…my line break worked in this response because I forgot to stick it in backticks

    ..use

    <br>
    Thread Starter frenchkitty

    (@frenchkitty)

    Thanks dmd54 for your quick answer, i just tried
    again but still doesn’t work. Gotta run but when i get back will try the padding.
    The thing that really bugs me is that it didn’t used to be like this, it used to look just fine without having to add any code. And now just out of the blue it’s stuck to h1, aargh.

    Thread Starter frenchkitty

    (@frenchkitty)

    Just added the padding to my css stylesheet and it worked, thanks!!

    I’m not a huge fan of line breaks either. I find they often time don’t work, so it’s better to control spacing with line heights, padding etc. Gives you greater control.

    Glad it worked!

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘silly silly question on adding line break’ is closed to new replies.