Working with xsl:output

There are two things we need to consider when generating output from our XML Document. The first is how the output is generated (what tool does the work), and the second is the format of the output. Of course, all XSL transformations produce some sort of output. XSLT would be of dubious worth otherwise. Control over the output format is provided via the xsl:output element. xsl:output is a topmost element within an XSL stylesheet and is responsible for how the output of the stylesheet is actually formatted. xsl:output has a number of attributes, but one of the most important is the method attribute. The method attribute must contain one of three values: xml, html, or text. For example

<xsl:output method="html"/>

specifies ...

Get XML Development with Java™ 2 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.