[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Calling named templates with a variable

Subject: Calling named templates with a variable
From: Mike Brown <mbrown@xxxxxxxxxxxxx>
Date: Fri, 25 Jun 1999 16:32:46 -0600
calling named template
I want to call a named template.
I don't know what its name is, but I can put the name in a variable.

<xsl:variable name="foo" expr="'SomeTemplateName'"/>
<xsl:call-template name="$foo"/>

With this, XT complains that no template is named "$foo".
Same if I use "{$foo}".

The spec does not say anything one way or the other on this issue.

What's the reason why a variable reference is not allowed here?
Is it because a variable's value can can be a node set?
Is it because we want people to be able to put '$' in the name of a
template?


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.