[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Re: [docbook-apps] Changing local customizations depending on XSLT processor?
On Tue, Apr 08, 2003 at 11:26:23PM +0200, Steinar Bang wrote: > Is it possible to use XSLT conditionals and xsl:vendor or > xsl:vendor-url, to only set values when a particular XSLT processor is > used? > > Specifically, I would like to only set these variables when using > Saxon or Xalan, but not while running xsltproc: > > <xsl:param name="use.extensions" select="'1'" /> > <xsl:param name="textinsert.extension" select="'1'" /> Yes, you can do something like this: <xsl:param name="use.extensions"> <xsl:variable name="vendor" select="system-property('xsl:vendor')"/> <xsl:choose> <xsl:when test="contains($vendor, 'SAXON')> <xsl:value-of select="1"/> </xsl:when> etc. <xsl:otherwise> <xsl:value-of select="0"/> </xsl:otherwise> </xsl:param> -- Bob Stayton 400 Encinal Street Publications Architect Santa Cruz, CA 95060 Technical Publications voice: (831) 427-7796 The SCO Group fax: (831) 429-1887 email: bobs@sco.com
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]