What is the full form of DTD?
The Full Form of DTD is Document Type Definition.
Are you aware of the tags and attributes employed on an HTML or XML document? These markup declarations can be defined as DTD or Document Type Definition. A document used to determine the XML document structure, DTD also correctly defines all the features of the XML language. Document Type Definition is divided into internal DTD and external DTD and specified inside or outside a document. DTD can be employed for the validity and grammar checks of an XML document. What it does is confirm if an XML document has a valid structure or not.
- Some elements are fixed and optional in the XML documents. DTD is used to define this
- DTD is used to validate the structure of the XML document
- Used for Grammar checks of the XML document
- DTD helps to define in which order the element takes place
Pros of Document Type Definition
- XML documents can get back their specific format with the help of DTD
- XML file is validated by the DTD
- DTD delivers proper documentation
- With the help of DTD, we can define an XML file effectively
Cons of Document Type Definition
- DTD is not easy to read and could be difficult to maintain if it’s too large
- Not object-oriented
- Very less support for documentation is received
- Namespaces are not backed by DTD
Candidates of the GATE Exam can stay tuned to BYJU’S and access the latest updates on the eligibility criteria, cut-off and other resources like the previous year papers or GATE syllabus.