XHTML - D-Zine Volume 11 :

XHTML is neater - it is stricter and cleaner than its predecessor.

Errors are not allowed
An XML Application always has perfect, neat, easy to read syntax. If just one thing is wrong, the XML Application terminates. Automatic error correction still occurs in browsers if malformed XHTML is sent with a content type of text/html. However, this content type is not allowed for XHTML 1.1 and onward. This article wont delve into this matter further.

Will work on all machines
The Internet is a myriad of web pages, some of them consist of hoplessly malformed HTML code that may work sometimes, and other times crash. XML is a language that must be well formed (ie: correct accoring to the specifications), thus standards are maintained and your web page will work on all machines.

Will display correctly on all machines
Another advantage of your code being well formed and valid it that it has a higher possibility that it will display correctly on all machines. With HTML, if you made a mistake in your code, a browser such as Internet Explorer will be able to overcome the error. The downside of this automatic recovery is that some browsers may not be capable of overcoming the error. This means that your website may work in Internet Explorer, but look terrible in Netscape.

Below is an example of a very badly formed HTML document:
Mark my <br>words!</html>

To prove my point of Internet Explorer being able to recover from bad code, take a look at the above example in action. It works perfectly, even though it shouldn't. In XML, everything must be marked up correctly without error and since XHTML is a reformualtion of HTML 4.01 with XML, it also applies to XHTML.

Not supported by old browsers
One downside is that some older browsers may struggle to read XHTML as it is a new language compared to HTML. This is a risk to accept with any new technology. If your website is attracting users with outdated software, it probably might not be worth switching to XHTML right away. The fact is, you can continue using HTML 4.01 until you have grandchildren, as HTML 4.01 is a W3C Standard that will remain over the years to come.



     "Better Than Books - As Easy As It Gets!"