|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] XT, call-template, parameters, default values
The output from the following example is $$22$ not $22$22$ like I expected.
At the intermediate stage VALUE is not specified but I need to select it in
order to pass it on to the next stage. It appears that selecting it binds it
so that I don't pick up the default in the final stage.
I can move my defaults up to the second level but this will make me copy
them a hundred times. Is there a better way?
<kTaxItem type="vendTaxEnum">22</kTaxItem>
<xsl:apply-templates select="kTaxItem"/>
<xsl:template match="*[@type='vendTaxEnum']">
<xsl:param name="value"/>
<xsl:call-template name="buildEnum">
<xsl:with-param name="value" select="$value"/>
<xsl:with-param name="enums"
select="document('../common/enum.xml')/enums/taxEnum"/>
</xsl:call-template>
</xsl:template>
<xsl:template name="buildEnum">
<xsl:param name="value" select="."/>
<xsl:param name="enum"/>
value is $<xsl:value-of select="$value"/>$<xsl:value-of select="."/>$
</xsl:template>
These templates have been simplified for the example. I'm using XT for my
XSL processor.
Jon Smirl
jonsmirl@xxxxxxxxxxxx
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








