[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
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
|
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
|