Some common DTDs have been put into lists. W3C has produced a list of DTDs commonly used in the web, which contains the "bare" HTML5 DTD, older XHTML/HTML DTDs, DTDs of common embedded XML-based formats like
MathML and
SVG as well as "compound" documents that combine those formats. Both W3C
HTML5 and its corresponding WHATWG version recommend browsers to only accept XHTML DTDs of certain FPIs and to prefer using internal logic over fetching external DTD files. It further specifies an "internal DTD" for XHTML which is merely a list of HTML entity names.
HTML 4.01 DTDs Strict DTD does not allow presentational markup with the argument that
Cascading Style Sheets should be used for that instead. This is how the Strict DTD looks: Transitional DTD allows some older PUBLIC and attributes that have been deprecated: If
frames are used, the Frameset DTD must be used instead, like this:
XHTML 1.0 DTDs XHTML's DTDs are also Strict, Transitional and Frameset. XHTML Strict DTD. No
deprecated tags are supported and the code must be written correctly according to XML Specification. XHTML Transitional DTD is like the XHTML Strict DTD, but deprecated tags are allowed. XHTML Frameset DTD is the only XHTML DTD that supports Frameset. The DTD is below.
XHTML 1.1 DTD XHTML 1.1 is the most current finalized revision of XHTML, introducing support for
XHTML Modularization. XHTML 1.1 has the stringency of XHTML 1.0 Strict.
XHTML Basic DTDs XHTML Basic 1.0 XHTML Basic 1.1
HTML5 DTD-less DOCTYPE HTML5 uses a DOCTYPE declaration which is very short, due to its lack of references to a DTD in the form of a URL or FPI. All it contains is the tag name of the root element of the document, HTML. In the words of the specification draft itself: , case-insensitively. With the exception of the lack of a URI or the FPI string (the FPI string is treated case sensitively by validators), this format (a case-insensitive match of the string !DOCTYPE HTML) is the same as found in the syntax of the SGML based HTML 4.01 DOCTYPE. Both in HTML4 and in HTML5, the formal syntax is defined in upper case letters, even if both lower case and mixes of lower case upper case are also treated as valid. In
XHTML5 the DOCTYPE must be a case-sensitive match of the string "". This is because in XHTML syntax all
HTML element names are required to be in lower case, including the root element referenced inside the HTML5 DOCTYPE. The DOCTYPE is optional in XHTML5 and may simply be omitted. However, if the
markup is to be
processed as both XML and HTML, a DOCTYPE should be used. ==See also==