These articles cover the basics as well as cutting edge developments in HTML.  Home HTML and CSS Articles Comprehensive Guide to Xhtml

Comprehensive Guide to Xhtml


image 1PART I: Introduction

(Note: i am assuming you already know html)

Since some time, the internet has been relying on HTML... or Hyper Text Markup Language... Since it's been invented, many tries to replace it have been thought up, but none as successfull as XHTML (eXtensive Hyper Text Markup Language)... let's say that it's HTML cleaned up...

oh yeah... it's kinda like a combination of XML and HTML... so... there's that

PART II: The Rules of XHTML

As you may (or may not now)... XHTML uses TAGS to work (like HTML before him)... these tags have this look:

<tag property="attribute">Content</tag>

This would be the opening tag (with the properties and attributes) the stuff inside the tag, and the closing tag (so it knows when it's done with that tag)...

some tags (like "img" or "br") require no content, so they don't use a closing tag, in XHTML they close themselves ("/" is the closing character) Example:

  <img src="/img_articles/5515/image.jpg" alt="text" />
<br />

ALL XHTML must begin and end with the  <html></html> tags (and all tags and their properties should be in lowercase).

The document has two main parts:

<head></head> (where you put info about the page, but not the actual content)
<body></body> (the content of the page)

XHTML requires everything done perfectly (it's very strict)... for example, when you open and close tags:

<h5><b> This is wrong </h5></b>
<h5><b> This is not wrong</b></h5>

Another XHTML rule is that all attributes are QUOTED

<img src=image.jpg alt=hello /> WRONG!
<img src="/img_articles/5515/image.jpg" alt="hello" /> RIGHT!!

XHTML also requires you to state wich type of document it is (before the html tag):

Comprehensive Guide to Xhtml


List Of Doctype Declarations

So... if you plan to move from HTML to XHTML, take notice of all these things.

PART III: Ending

to validate your Markup (HTML or XHTML) go to:

the W3C validation service

I hope this was usefull for those of you that use HTML already, and more usefull for those who want to take a peak at the world of Markup Languages.

Author's URL: Unbinded.net
These articles cover the basics as well as cutting edge developments in HTML. More Articles: Featured Materials | Fresh Materials | More HTML Tutorials at Markuptutorials.com

No comments yet...
Add comments to "Comprehensive Guide to Xhtml"

Captcha