4. DTD External Declaration

A DTD can be included external to an XML source file. An external DTD declaration is required to be wrapped in a DOCTYPE definition.

Example 4.1 External DTD Declaration
<!DOCTYPE rootelement SYSTEM "filename">	
Example 4.2 XML Document with an External DTD
<?xml version="1.0"?>
<!DOCTYPE rootelement SYSTEM "rootelement.dtd">
	<childelement>Child element.</childelement>
Example 4.3 Content of rootelement.dtd DTD
<!ELEMENT rootelement (childelement1)>
<!ELEMENT childelement (#PCDATA)>