Class 2 – The Bare Minimum Elements of an XHTML Page

Here is the outline of the very minimal number of elements necessary for a blank XHTML web page. Recall that the first two lines are more or less a formality. Every XHTML document begins with an <html> tag and ends with a </html> tag.  Inside of this go a <head> and a <body> tag.  Inside of the <head> tag, there must be a <title> tag with the title of your page inside it.

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
 <head>
   <title>The Title of Your Page</title>
 </head>
 <body>
   <!-- the contents of the page go here -->
 </body>
</html>

Related posts:

  1. Class 2 – Common XHTML Elements
  2. Class 2 – Usage of the Most Common XHTML Elements
  3. Class 2 – XHTML Syntax
  4. Class 2 – Special vs. Arbitrary XHTML Attributes

Tags:

Leave a Reply