wheresrhys
wheresrhys

Reputation: 23500

How to markup site title for accessibility

On my home page I'm using a h1 tag for the site title.

On internal pages I'm using h1 for the page title, but I'm wondering what is the best way to mark up the site title on these pages in XHTML?

Upvotes: 0

Views: 352

Answers (2)

Jon Gibbins
Jon Gibbins

Reputation: 1086

If you're looking at XHTML 1, I tend to use a <div> on inner pages to mark up the site's name, perhaps with a <strong> for some emphasis. For accessibility purposes, if you are including the site's name in the page title, you should be mostly covered by that. Screenreader software tend to read out the page title when pages first load, and that info is readily available to a user (Insert-T keystroke in JAWS for Windows).

XHTML 2 actually has a better solution, which is similar to what HTML 5 does, allowing you to build heading hierarchies per section. Bruce Lawson explains this best: Headings in HTML 5 and Accessibility

Upvotes: 2

Oded
Oded

Reputation: 498972

The H1-H6 tags are semantic tags and should be used the same way in XHTML.

Upvotes: 2

Related Questions