January 2003
Beginner to intermediate
1200 pages
23h 42m
English
Prologs come at the very beginning of XML documents. In fact, XML documents do not need prologs to be considered well formed. However, the W3C recommends that you include at least the XML declaration, which indicates the version of XML, in the document's prolog. In general, prologs can contain XML declarations, comments, processing instructions, whitespace, and doctype declaration(s).
Here's an example. In this case, I've marked the document's prolog, which contains an XML declaration, a processing instruction, and a DTD (which we'll see more about in the next chapter):
<?xml version = "1.0" standalone="yes"?> <?xml-stylesheet type="text/css" href="greeting.css"?> <!DOCTYPE DOCUMENT [ <!ELEMENT DOCUMENT (CUSTOMER)*> <!ELEMENT CUSTOMER ...