Lab #5 - XSLT Processing

CS 183 - Hypermedia and the Web

The goal of this laboratory assignment is to exercise knowledge of XPath path expressions and XSLT stylesheets by creating a functional stylesheet. So long as you have followed the setup for lab #1, no additional setup is necessary for this lab assignment.

The assignment is very similar to the sax parsing assignment in lab #1. That is:

1. Using use this XML file as input, create an XSLT stylesheet that, after execution, creates an HTML file that contains an html table with each row corresponding an album record in the xml. The table should have five columns organized as follows:

These can be found in the XML elements and attributes:

The output should have the following attributes. Where the output format is unspecified, it can be in any reasonable format.

Note: * - you may consider using a separate xsl:template for these

Note: To manually operate the Xalan XSLT processor, use the following command at the unix command prompt (all on one line):

java org.apache.xalan.xslt.Process -in {input XML file} -xsl {your XSLT file} -out {name of your output HTML file}

For example:

java org.apache.xalan.xslt.Process -in /afs/cats.ucsc.edu/courses/cmps183-jw/amazon.xml -xsl sasha_lab5.xslt -out sasha_lab5.html

Note: The input file for the lab is located at:

/afs/cats.ucsc.edu/courses/cmps183-jw/amazon.xml

For submission please email Sasha [at] cse [dot] ucsc [dot] edu your xsl stylesheet file and the html output file you generated.

Last modified: 2/24/2004