O'Reilly logo

Special Edition Using XSLT by Michael Floyd

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Debugging Style Sheets

Although there are some rudimentary tools available for debugging style sheets, the best method for locating problems is to trace or step through your style sheet. To step through a style sheet, it’s important to understand how a style sheet is executed. Chapter 2 described the data model and showed this process. Chapter 4 also described the process in greater detail.

However, it’s important to remember that template rules are not generally executed in the order you’ve written them. The root template is always executed first. How your other templates are executed depends entirely on how you’ve designed the rest of your style sheet.

In general, I promote the following structure for all style sheets:

 <xsl:stylesheet xmlns:xsl=”namespaces ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required