O'Reilly logo

Real World XML by Steven Holzner

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Processing Instructions

As their name implies, processing instructions are instructions to the XML processor. These instructions start with <? and end with ?>. The only restriction here is that you can't use <?xml?> (or <?XML?>, which is also reserved). Processing instructions must be understood by the XML processor, so they're processor-dependant, not built into the XML recommendation.

A very common and well-understood processing instruction (although, like other processing instructions, not a part of the XML 1.0 recommendation) is <?xml-stylesheet?>, which connects a style sheet with the document. Here's an example:

<?xml version = "1.0" standalone="yes"?> 
<?xml-stylesheet type="text/css" href="greeting.css"?> <DOCUMENT> <GREETING> Hello From ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required