Quick Start Guide

176 Tutorial: Displaying XML Data
In this tutorial you’ll convert the existing specials page (an HTML page) to
an XSLT page so that you can display XML data on the page. You’ll also
apply styles to the XML data so that the appearance of the data is in
keeping with the rest of the page.
If youre comfortable working with XML, XSLT, and client-side
transformations, you can skip to “Convert an HTML page to an XSLT
page” on page 179. If you are new to any of these concepts, read the next
sections.
Learn about using XML and XSL
with web pages
Extensible Markup Language (XML) is a language that lets you structure
information. Like HTML, XML lets you structure your information using
tags, but XML tags are not predefined as HTML tags are. Instead, XML
lets you create tags that best define your data structure. Tags are nested
within others to create a schema of parent and child tags. Like most
HTML tags, all tags in an XML schema have an opening and closing tag.
The following example illustrates the basic structure of an XML file:
<?xml version=“1.0”>
<mybooks>
<book bookid=“1”>
<pubdate>03/01/2004</pubdate>
<title>Displaying XML Data with Macromedia Dreamweaver</
title>
<author>Charles Brown</author>
</book>
<book bookid=“2”>
<pubdate>04/08/2004</pubdate>
<title>Understanding XML</title>
<author>John Thompson</author>
</book>
</mybooks>
In this example, each parent <book> tag contains three child tags:
<pubdate>, <title>, and <author>. But each <book> tag is also a child
tag of the
<mybooks> tag, which is one level higher in the schema. You can
name and structure XML tags in any way you like, provided that you nest
tags accordingly within others, and assign each opening tag a
corresponding closing tag.