A DOCTYPE declaration can contain an internal and/or reference an external Document Type Definition subset
The SYSTEM identifier can be used to reference an external DTD grammar.
<!DOCTYPE root-name SYSTEM "uri-reference">
The PUBLIC identifier can be used to 'name' the reference to an external DTD grammar.
<!DOCTYPE root-name PUBLIC "public-identifier" "uri-reference">
The DOCTYPE declaration can also specify an internal DTD Grammar.
<!DOCTYPE root [ <!ELEMENT root (child)> <!ATTLIST root attribute #IMPLIED> ... <!ENTITY copy "©"> ]> <root> ... </root>
Or a combination of external references and internal DTD Grammars can be specified.
<!DOCTYPE root SYSTEM "uri-reference" [ <!ELEMENT root (child)> <!ATTLIST root attribute #IMPLIED> ... <!ENTITY copy "©"> ]> <root> ... </root>
The internal grammar takes precedence for entity and attribute-list declaration.