E-mail List Archives

Re: Use of <H> tag in PDF


From: Alastair Campbell
Date: Aug 31, 2013 2:09PM

Duff Johnson wrote:

> Since web pages already have Title tags why is H1 so commonly press-ganged
> into the role of an ersatz Title tag? Does this not make the page's true
> title ambiguous? What's the point / value of this practice other than to
> screw things up and effectively a heading level from the 6 available?

There is some duplication, but they do serve different purposes.

The title is for more than just the page you've opened, it may be your
first interaction with the site, so it often contains more information than
the main heading of the page. (Imagine landing on page 26 of a PDF, where
the first heading of that page and the title would be different.) Its also
used by search engines for the link to the page.

Typically we recommend a title includes:
Page name | Site name | Section name

The 'main' heading would only have the page name.

That's really where "only have one H1" comes from, there is generally a
main heading for (a web) page, visually. It's generally at the top of the
content area, so becomes a good anchor point for people (Especially screen
reader users to skip to. In Jaws, press 1.).

Fair enough, but why preclude deeply structured content in HTML? What was /
> is the point? Why wasn't it fixed for HTML5? Etc.

I don't know why it was limited to 6 levels, I guess the new HTML5
(levelless) algorithm would not have that restriction, but it isn't
backwards compatible so I don't see it working for a while.

Given the ability to break a web page into multiple pages, getting down to
H6 is pretty rare unless you are making something very large (even the WCAG
2 doc only uses H1-3).