Subject: Re: [xsl] Conditional indentation? From: Jeni Tennison <jeni@xxxxxxxxxxxxxxxx> Date: Mon, 8 Apr 2002 09:41:50 +0100 |
Chris Maden wrote: > At 15:02 7/4/02, Ned Batchelder wrote: >>I tried setting a parameter to the stylesheet and then using: >> >><xsl:output method='html' indent='{$indent}' /> >> >>but the indent attribute is not an attribute value template. First >>question: why not? > > Variables may be set by other top-level elements, and that would > require that the XSLT engine evaluate all of those variables > (potentially deeply investigating the source XML) before setting up > its output environment. Note that this changes in XSLT 2.0 (and in the XSLT 1.1 Working Draft), in which all the attributes on xsl:output (aside from the name) are attribute value templates. In these versions, the "output environment" can change during the course of the stylesheet, as you generate different documents, so it's less important to get everything set up in advance. One possible solution is therefore switching to a processor that supports XSLT 1.1/2.0 (e.g. Saxon or jd.xslt). Cheers, Jeni --- Jeni Tennison http://www.jenitennison.com/ XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Conditional indentation?, Christopher R. Maden | Thread | RE: [xsl] Conditional indentation?, Michael Kay |
Re: [xsl] Re: Removing namespaces f, Christopher R. Maden | Date | Re: [xsl] Writing a stylesheet to c, Jeni Tennison |
Month |