Lean and clean! Building a site with web standards
5. Semantic code
Semantic code uses html elements for their given purpose. Well structured HTML will have semantic meaning for a wide range of users and user agents (browsers without style sheets, text browsers, PDAs, search engines etc.)
In simple terms, this means:
- for headings, use heading elements starting with H1
- for paragraphs of text, use a paragraph element
- for lists, use a list item element
You should use standard HTML elements for your markup and avoid styling HTML elements to look like other HTML elements. For example, avoid styling <div> elements to look like headings.