Листинг 1.7. Пример каталога музыкальной библиотеки (MyMusic.xml)
<?xml version="l.0"?>
<library>
<cd>
<title> Just Singin' Along</title>
<artist> The Happy Guys</artist>
<description>
A lovely collection of songs that the whole family can sing right along with.
</description>
<song> <title> I'm Really Fine</title> </song>
<song> <title> Can't Stop Grinnin'</title> </song>
<song> <title> Things Are Swell</title> </song>
<purchase_date> 2/23/1954</purchase_date>
</cd>
<cd>
<title> It's Dot Com Enough for Me: Songs From Silicon Somewhere </title>
<artist> The Nettizens</artist>
<description> A collection of the best folk music from Internet companies. </description>
<song> <title> My B2B Is B-R-0-K-E</title> </song>
<song> <title> Workin' in a Cubicle</title> </song>
<song> <title> Killer Content Strategy</title> </song>
<song> <title> She Took the Bricks. I Got the Clicks </title> </song>
<purcnase_date> 7/12/2000</purchase_date>
</cd>
</library>
Допустим, вы хотите создать и напечатать список всего, что имеется в вашей библиотеке. Один из способов сделать это заключается в том, чтобы применить к документу MyMusic.xml таблицу стилей, которая трансформирует его в формат HTML. В листинге 1.8 приводится такая таблица стилей.