DTD
Dan Tobias (Talk | contribs) (Created page with "{{FormatInfo |formattype=electronic |subcat=Markup |extensions={{ext|dtd}} |mimetypes={{mimetype|application/xml-dtd}} |locfdd={{LoCFDD|fdd000076}} |pronom={{PRONOM|x-fmt/315}...") |
|||
Line 1: | Line 1: | ||
{{FormatInfo | {{FormatInfo | ||
|formattype=electronic | |formattype=electronic | ||
− | |subcat= | + | |subcat=Metaformats |
|extensions={{ext|dtd}} | |extensions={{ext|dtd}} | ||
|mimetypes={{mimetype|application/xml-dtd}} | |mimetypes={{mimetype|application/xml-dtd}} | ||
Line 24: | Line 24: | ||
* [[Wikipedia:Document type definition|Wikipedia article]] | * [[Wikipedia:Document type definition|Wikipedia article]] | ||
* [http://www.w3schools.com/dtd/ DTD tutorial] | * [http://www.w3schools.com/dtd/ DTD tutorial] | ||
+ | |||
+ | [[Category:Markup]] |
Revision as of 21:16, 14 April 2016
A DTD (Document Type Definition) is the official means of defining the syntax of a variety of SGML, XML, or related-format document, though more recently XML formats are being defined using XML Schema Definitions instead because this latter format is cognizant of multiple namespaces.
As HTML was originally an application of SGML, DTDs were used. XHTML is an XML version of HTML and also uses DTDs, but HTML 5 is no longer defined based on such document types and instead has a more "pragmatic" spec based on defining the expected behavior of a properly implemented parser.
Documents using a DTD have a DOCTYPE declaration at their head (beneath an optional XML declaration in the case of XML), and sometimes these declarations include a URL which might resolve to an appropriate DTD file (but there need not be one directly referenced this way; document types can also be determined by matching a known public identifier).