Document type definition subsets A DTD can have either an external portion (or subset) or an internal portion or both. Together, these subsets are regarded as the complete DTD. The external DTD subset is in an XML file (or group of files) by itself. The internal DTD subset is placed in the beginning of the XML file within the document type declaration before the root element start tag. The document type declaration refers to the file containing the external DTD subset file name (block.dtd in this case) and contains the DTD name (block in this case) which must be the top level element in the XML file.