Difference between html and xhtml

Uncategorized 0 Comment 3

XHTML is a stricter and cleaner version of HTML.
XHTML stands for EXtensible HyperText Markup Language.
XHTML is supported by all major browsers.
XHTML is HTML defined as an XML application

XHTML elements must be properly nested
XHTML elements must always be closed
XHTML elements must be in lowercase
XHTML Attribute values must be quoted
XHTML documents must have one root element
Example:
This text is bold and italic (bad command)
This text is bold and italic (good)

An XHTML document must have a DOCTYPE declaration.
The html, head, title, and body elements must also be present.

It contains three main parts
1. DOCTYPE 2. head 3. body

Leave a comment

You must be logged in to post a comment.

© 2016 4frienz. Powered By Flowers

Back to Top