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

Re: Using xsl:apply-templates with xsl:with-param

Subject: Re: Using xsl:apply-templates with xsl:with-param
From: "Sebastian Rahtz" <sebastian.rahtz@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
Date: Mon, 15 May 2000 23:16:59 +0100 (BST)
apply templates with param
Ron Ten-Hove writes:
 > How is xsl:with-param supposed to work from within an xsl:apply-templates
 > element?  The recommendation doesn't seem to actually spell it out, other
 > that saying it is allowed.  Consider the following:

...
 >             <xsl:apply-templates>
 >                 <xsl:with-param name="param">List</xsl:with-param>
 >             </xsl:apply-templates>
 >         </root>

if you say

  <xsl:apply-templates select="doc/chapter">

It has the result you expect. This is because the step from <root> to
<doc> to <chapter> is by separate (implicit) <xsl:apply-templates>
 rules, and the parameter is not passed through automatically. It
passes to the next level (when <doc> is processed), but there is no
reason for it to be passed by <doc> to <chapter>.

<xsl:apply-templates/> does not process all the descendants, despite
appearances. 

Sebastian Rahtz


 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.