Data · 1 file
Sample DTD File
A Document Type Definition, the original way to declare the structure of an XML or SGML document.
DTD · 524 B
Document Type Definition (DTD)
A DTD with element content models, optional elements, ID and enumerated attributes, and an entity declaration.
CC0 · free for any use · Verified by an independent tool · Report a problem
<!-- DTD for a simple customer list — samplefiles.com -->
<!ELEMENT customers (customer+)>
<!ATTLIST customers generator CDATA #IMPLIED>
<!ELEMENT customer (first_name, last_name, email, phone?, company?, city, country)>
<!ATTLIST customer
id ID #REQUIRED
active (true|false) "true">
<!ELEMENT first_name (#PCDATA)>
<!ELEMENT last_name (#PCDATA)>
<!ELEMENT email (#PCDATA)>
<!ELEMENT phone (#PCDATA)>
<!ELEMENT company (#PCDATA)>
<!ELEMENT city (#PCDATA)>
<!ELEMENT country (#PCDATA)>
<!ENTITY site "samplefiles.com">File details
Download from the command line
curl -L -o customers.dtd https://files.samplefiles.com/data/dtd/customers.dtdwget https://files.samplefiles.com/data/dtd/customers.dtdhttps://files.samplefiles.com/data/dtd/customers.dtdprintf '%s %s\n' 2efbc1e122036f9ce8833d03d4063c355edb43047b70b2a7cfeddef3dec648a0 customers.dtd | shasum -a 256 -cOr check the download in your browser with the checksum calculator.