SitePoint Sponsor

User Tag List

Results 1 to 6 of 6
  1. #1
    Non-Member
    Join Date
    Jan 2007
    Posts
    148
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Correct use of heading tags

    Hi I am a bit confused as to how to use the heading tags correctly. I have seen some sites use the h1 tag for their company logo or even for the site map, while I usually use the h1 tag for the most prominent or important text heading in the page. Any guidelines?

  2. #2
    SitePoint Author silver trophybronze trophy

    Join Date
    Nov 2004
    Location
    Ankh-Morpork
    Posts
    12,159
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    H1 should describe the content of the entire document.
    H2 elements describe the major sections of the document.
    H3 elements describe subsections.
    H4 elements describe sub-subsections.

    etc.
    Birnam wood is come to Dunsinane

  3. #3
    Non-Member
    Join Date
    Jan 2007
    Posts
    148
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    so for example on alistapart.com the image is the h1, is that a correct usage of h1, in the sense that it can be used also for images and not for text only? thanks

  4. #4
    SitePoint Addict rochow's Avatar
    Join Date
    Oct 2006
    Location
    Queensland, Australia
    Posts
    300
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The logo should never be the H1. The major theme of the page is the H1 - "sitemap", "about us" and so forth. The only time it could pass as the H1 is if the site has 1 page, for example a landing page and the logo/title is the same thing.

  5. #5
    SitePoint Author silver trophybronze trophy

    Join Date
    Nov 2004
    Location
    Ankh-Morpork
    Posts
    12,159
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by jpgalea View Post
    so for example on alistapart.com the image is the h1, is that a correct usage of h1, in the sense that it can be used also for images and not for text only? thanks
    An H1 can contain an image, since images are merely an alternative content form. Of course, the image must have a text equivalent (alt attribute) than conveys the same information as the image.

    I wouldn't necessarily recommend it, but it's not against the rules.

    The start page of a site is a bit of a special case. It's not uncommon to use the site/company/organisation name as the H1 on the start page. On other pages the H1 should describe the content of the particular document, though.
    Birnam wood is come to Dunsinane

  6. #6
    Non-Member
    Join Date
    Jan 2007
    Posts
    148
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    ok got it thanks alot


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
  •