Create an XHTML Web Page

for those who already know HTML

  1. Create a Page Template
  2. Create a Class Home Page
  3. Validate the Page
  1. Put the Page on the Server
  2. Submit the Assignment

1. Create a Page Template


The first step in any new coding adventure is to build a template file as the basis for your future work. Some of the code editors will create a template for you automatically, but if you have your own, you won't be dependent on any one editor.

To keep things simple, this time start Notepad or some other non-code-specific editor. Copy these lines into your file:

  1. DOCTYPE statement:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd ">

  2. HTML namespace declaration:
    <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  3. Character set (charset) meta tag:
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />

When you're done with these, put in the normal HTML tags to open and close the head, body, and html sections.

Add a title line, and a meta tag for the author that includes your name. The author meta tag looks like this:
<meta name="Author" content="Sarah Strong">

Save the file as xhtml.htm.

Validate the template using W3C's validator, http://validator.w3.org/.

2. Create a Class Home Page


Using your XHTML template page, create an XHTML class home page that tastefully includes these elements:

  • Class and section numbers;
  • Your name;
  • One or two images;
  • A list of assignments, which you will like to the page as you complete the assignments. Use the on-line class schedule to compile this list. (Include a link to your template page!)

Save the page as home.htm (Do not name it index or default!)

3. Validate the Page


Validate the page using W3C's validator, http://validator.w3.org/. Make any corrections that are necessary, and re-validate until the validator approves of your page. Print the page for submission.

4. Put the Page on the Server


Use FTP to create a directory for this class on your Web space on the college server. Put your template file and your home page in the class directory.

5. Submit the Assignment


Print the following:

  1. A copy of the Grading Guide page; hand-write your name and Exercise X10h in the upper right;
  2. A copy of your page on the Web in a browser (make sure the URL of the page appears in the header or footer);
  3. A copy of the code for your page, printed in landscape mode;
  4. A copy of the W3C validator report approving your page.

Staple these and submit to your Instructor.


 
to Top About This Document
Audience

This module is for people who know HTML and have learned about XHTML, and want to build an XHTML Web page.

 

Objectives

On successful completion of this module, you will be able to:

  1. Create the framework for an XHTML Web page;
  2. Insert the proper tags referring to the DTD, namespace declaration, and character coding;
  3. Use tags according to the XHTML specifications to display an attractive page.
Module X10h: Create an XHTML Web Page

This document is part of a modular instruction series in Computer Instruction. For more information, see the overview or the list of modules in this series, X. This document has been used in the following classes: INP 270.
History:
Original: 20 January 2003
Last modification: Monday, 31-Aug-2009 11:48:07 EDT
Copyright
Copyright © 2003, Laurence J. Krieg, Washtenaw Community College
Instructors: You may point to this file in your Web-based materials; however, its location may change without notice.
Students: You are welcome to make a copy for your personal use.
All other uses: Please contact the author, Laurence J. Krieg, for permission: krieg@ieee.org.