Jump to content

XSLT template to return a value??


sajesh

Recommended Posts

When you call a template, you're invoking it and thus return a value from it in the output. That is the behaviour. I'm not sure what you're asking for here.I mean, if you already know templates could be called, you should know that for example:

<xsl:template name="template1">1</xsl:template><xsl:template match="/">0<xsl:call-template name="template1"/></xsl:template>

Will produce "01", scince "template1" outputs "1" and the main template returns "0" before "template1" is invoked.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...