Beginning XML, 3rd Edition David Hunter Andrew Watt Jeff Rafter Kurt Cagle John Duckett 2004 XML is a markup language, derived from SGML. To be well-formed an XML document must satisfy several rules about its structure. To help unambiguously identify the names of elements and attributes the notion of an XML namespace is used. A document type definition, DTD, is a way to specify the permitted structure of an XML document. W3C XML Schema and Relax NG are two schema languages to specify the structure of XML documents.