Semantic Page Layout
Screen readers, search engines and other developers understand a page through its structure. You will mark up a page's regions with header, nav, main, article, section, aside and footer, and know when a plain div or span is the right choice.
Updated
Semantic HTML
- What Semantic HTML Means (Apprentice): Semantic elements such as strong, nav, main and footer say what their content is, so the HTML describes the content and CSS handles how it looks.
Page Regions
- Header, Nav, Main and Footer (Apprentice): Mark up the four big parts of almost every web page (its top, its menu, its main content and its bottom) with header, nav, main and footer, so screen readers and search engines can find their way around it.
- Article, Section and Aside (Apprentice): Inside the main content, mark up each piece that stands on its own as an article, each themed group with its own heading as a section, and related extras as an aside, using one short test for each.
- Div and Span: Boxes with No Meaning (Apprentice): Div and span are plain boxes that say nothing about what they hold, so you use them to group or style content only when no meaningful element fits, and you learn to spot the "div soup" that happens when they're used for everything.
Exercise: From Div Soup to Semantic HTML
- Exercise: From Div Soup to Semantic HTML (Apprentice): Rewrite the Maple Street Library's div-soup news page with header, nav, main, article, section, aside and footer, without changing a word, and watch its ready-made stylesheet and its checks reward every region you mark up.