The XML output format we used in the last example was pretty straightforward. Every piece of data is contained within its own XML element; however, it is very common for XML files to be more complex, with subelements being repeated within a parent element, and data items being held in XML attributes rather than in elements.
In this example, we will produce an XML file that contains data about customer orders that have been dispatched. This file will contain the following information:
The XML format ...