Subject: [xsl] name of the current mode From: Stefan Krause <stf@xxxxxxxx> Date: Sat, 14 Nov 2009 20:25:36 +0100 |
Hello, is there any way to detect the name of the current mode during the processing of the input document? I tried a approach over several matching templates for each mode: <xsl:function name="test:detect-mode"> <xsl:variable name="temp_element" as="element()"> <test:detect/> </xsl:variable> <xsl:apply-templates select="$temp_element" mode="#current"/> </xsl:function> <xsl:template match="test:detect" mode="#default">#default</xsl:template> <xsl:template match="test:detect" mode="Mode_A">Mode_A</xsl:template> <xsl:template match="test:detect" mode="Mode_B">Mode_B</xsl:template> <xsl:template match="test:detect" mode="#all" priority="-1">#not_detected</xsl:template> Unfotunately, this only works if I know all possible modes in advance. Best regards, Stefan
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] Do xsl processors contain, Michael Kay | Thread | Re: [xsl] name of the current mode, G. Ken Holman |
RE: [xsl] Do xsl processors contain, Michael Kay | Date | Re: [xsl] name of the current mode, G. Ken Holman |
Month |