• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

DTD Declarations

Oddly, the DTD uses syntax that has a confusing similarity to XML syntax but is completely different. A DTD declaration has the form

Open delimiter (DTD mimics XML by using < to open the declaration.)

Declaration (Unlike XML, DTD has a finite set of predetermined declarations.)

Name (Name of this object in the XML file.)

Rule (Defines constraints on the content of this object.)

Close delimiter (>)

Example: <!ELEMENT Quiz ((Q,A,A+)*)> This is an !ELEMENT declaration that declares a type of XML element called a Quiz whose content is a series of Qs, each followed by two or more As.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint