Introduction to .
XHTML is a new generation of HTML markup language.
The purpose of XHTML is to replace HTML.
XHTML tags are exactly the same as HTML.
The syntax of XHTML is much stricter than HTML.
XHTML Extensible Hypertext Markup Language.
All tags and attributes must be all lowercase
One-sided tags must be turned off. For example: <br> ——> <br />
All attribute values must be enclosed in quotation marks.
All attributes must have values. For example: <hr noshade> —— <hr noshade = “noshade” />
Tags must be nested sequentially, with the outer layer nested within the inner layer, and one layer within another. layer.
XHTML web pages must have DTD document type definition code.
##DTD document type definition
#The purpose of DTD document type definition: it is a verification mechanism, that is, to check whether the XHTML markup syntax you wrote is legitimate.
There are three major types of DTD:
(1) Strict DTD
In strict type In the DTD, various presentation tags can no longer be used. For example: <font>, <b>, <body bgColor>requires that CSS must be used to replace various performance tags.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd" >(2) Transitional DTD
In the transitional DTD, you can continue to use the expression writing method in HTML.These performance markers can still be used. Such as: <font>, <b>, <body bgColor>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www .w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">(3)Framework DTD
<!DOCTYPE html PUBLIC " -//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">Next Section