Forum Moderators: open
Every site has it's own title. Most sites have a slogan. For now, let's assume that an imaginary website we are talking about has both.
How would you markup the page:
<body>
<h1>Site Title</h1>
<h2>The best slogan</h2>
<h1>Page Title</h1>
<h2>subtitle</h1>
</body>
<body>
<p>Site Title</p>
<p>The best slogan</p>
<h1>Page Title</h1>
<h2>subtitle</h1>
</body>
or maybe there are other solutions?
In fact, I often place a slogan, tagline, or even the site title, in a graphic. I usually don't really want that text hammered home, over and over, at the top of each page. Well, maybe sometimes I do, depending on keywords involved, or the depth of the site, intensity of the competition.
My point is that I consciously decide when I want that kind of text on a page and when graphic text offers a chance to conentrate the page on other keywords (or even to back off from too high a kw density.)
<head>
<style type="text/css">
body {background:#fff url(site-logo-with-tagline.jpg) no-repeat top left;}
</style>
</head>
<body>
<h1>Page Title</h1>
<h2>subtitle</h1>
</body>
Repeating the same site name/tagline in hx elements on every page is a complete waste. The searcher is not looking for your site name or your tagline. In fact he doesn't even care about your site: he's looking for the information on that particular page.
What about in the case of a blog. Usually on the main page there are listings of headers and articles (or their snippets). Header is clickable for a separate page with a full entry and sometimes comments.
So each title on the main page would be an h1?
An H1 tag indicates a page's main topic - therefore usually you would have one H1 element per page, and only rarely one or two more. If it seems like there should be multiple H1 tags most of the time, then I would take a hard look at the site's information architecture - it's probably too chaotic for best results. And from a purist stand point, anyway, the site's title does not seem like it should be the main topic of any inner page.
The blog situation is interesting to consider. In most cases, each separate topic is NOT the main topic for the page. So that feels like an H2 element to me, especially if there is some related content below the clickable header. And if each comment has a title, that would be an H3. The H1 would then be...what, recent postings or something like that?
<p class="bannertext">Top Banner Text</p>
<h1>Topic for this page</h1>
If the name of the site is included on the page - somewhere near the top, say - it probably shouldn't be enclosed in <h1> tags.
If you imagine a standard academic paper it may be outlined like this:
Main Heading <h1>
1.0 <h2>
2.0 <h2>
3.0 <h2>
3.1 <h3>
3.2 <h3>
3.2.1 <h4>
3.2.2 <h4>
3.3 <h3>
4.0 <h2>
In a few cases, I have some areas of text that don't really fit into an outline of the page. At these times, I normally wrap the text in a <div> and it doesn't really take a place in the semantics of the page at all.
Slightly off topic, but related...
The searcher is not looking for your site name or your tagline. In fact he doesn't even care about your site: he's looking for the information on that particular page.
Putting it quite brutally, it sometimes doesn't matter what the searcher is looking for. That is, it matters a lot, but there may still be good reason to include a tagline or site name even if the searcher doesn't care about that particular bit of information. Sometimes you need that tagline, or title, or whatever, in order to integrate your branding with your product. In some cases, it may even attract the attention of the searcher and get him interested in your site, even though he might not have cared when he visited.
My site header has an extremely short (15px high) tagline. It appears on every page, at the very top, unobtrusive but highly visible and obvious. It defines what the site is all about. It's the essence of the site, if you will, summed up in a single, catchy phrase. We've gotten a lot of comments from people who have appreciated it being there.