This site will look much better in a browser that supports web standards, but it is accessible to any browser or Internet device.
At the beginning of the source for this web page I have written this:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
Why is this required?
The short answer is validation. W3C have set the standards for XHTML. After a year of applying a transitional form of XHTML, I have migrated to a strict version. To ensure that this web page conforms to the standards set by W3C, a parser (included as part of an XML-enabled browser) uses a DTD (Document Type Definition) held on a W3C server. A DTD specifies XML syntax, the rules for the language. Any failure to correctly adhere to these constraints will mean that the page cannot be classed as XHTML. A failure to validate, results from markup that is not "well formed".
W3C provide a full listing of required syntax, but here are few tips based on my experience of writing XHTML.
You can validate any of your pages by going to http://validator.w3.org/ where you will be presented with a choice of either supplying a URI or choosing a file residing on your computer.
For an XHTML tutorial go here.
An article on XHTML by Jeffrey Zeldman can be found here.
Next page » Design Software
Previous page « Introduction to XHTML