Skip to Content
Real World XML
book

Real World XML

by Steven Holzner
January 2003
Beginner to intermediate content levelBeginner to intermediate
1200 pages
23h 42m
English
Peachpit Press
Content preview from Real World XML

The Prolog

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 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Inside XML

Inside XML

Steven Holzner
XML Hacks

XML Hacks

Michael Fitzgerald

Publisher Resources

ISBN: 0735712867Purchase book