SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Enthusiast
    Join Date
    Jun 2002
    Posts
    51
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    <h1> <h2> linespacing help please

    ok i am trying to get my site google ready with h1 and h2 tags and i am having a problem getting the h2 to have proper spacing under and over the text links

    here is the file to see what its showing and what i have come got...

    the top is the "over spaced version" and the bottom is the proper look i want (only with h2 tags)...

    and here is the h2 css code

    h2 {
    font: bold 12px Arial, Tahoma, Verdana, Helvetica, sans-serif;
    }

    h2 a {
    font: bold 12px Arial, Tahoma, Verdana, Helvetica, sans-serif;
    margin-top: -10px;
    }

    can anyone help? linespacing isn't working

  2. #2
    Web-coding NINJA! silver trophy beetle's Avatar
    Join Date
    Jul 2002
    Location
    Dallas, TX
    Posts
    2,900
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    put the margin-attribute on the h2 declaration

    div.leftbox h2 {
    margin: 0;
    }

    Or something like that
    beetle a.k.a. Peter Bailey
    blogs: php | prophp | security | design | zen | software
    refs: dhtml | gecko | prototype | phpdocs | unicode | charsets
    tools: ide | ftp | regex | ffdev




  3. #3
    SitePoint Evangelist S7even's Avatar
    Join Date
    Jun 2002
    Posts
    481
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I am not sure if this is what you mean:
    Code:
    h2 {
     margin: 0;
    }
    edit:
    I should refresh the page before replying!


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •