XSLT Patterns

XSLT provides a very useful subset of XQL syntax for patterning. In fact, XQL was first described as a superset of the XSL pattern syntax. There is limited support for XSL in IE5, and this section provides some examples of using XSL patterns in IE5.

You will remember from Chapters 10 and 11 that a pattern in XSL is the syntax that selects the nodes that will be transformed. Here, we'll just give a few examples of this syntax.

Examples of XSLT Queries

To view these examples, you must use IE5, which provides some support for the XSL spec. Simply add a processing instruction to the head of movies.xml, as follows:

<?xml version="1.0" standalone="no"?>
<?xml-stylesheet type="text/xsl" href="movies4.xsl"?>

Of course, the href of the ...

Get XML Unleashed now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.