a minimal valid web page

Use View -> Page Source (or equivalent) in your browser to see nearly minimal XHTML 1.0 code: you need a DOCTYPE, namespace (xmlns), character set, and title (I think a title is required. Take it out and see.)

Note that the first line--the xml, version, and encoding tag, has to be removed if you're using PHP. A page will validate without it, but I use it if there's no PHP.

The code at the bottom is not required. It just gives you a convenient place to click to validate a page.

back to lesson 1


Valid XHTML 1.0 Strict