Subject: RE: apply templates with with-param on Xalan From: Kay Michael <Michael.Kay@xxxxxxx> Date: Tue, 25 Jul 2000 13:30:12 +0100 |
> So now Im unsure how to proceede. I still dont understand > why the parameter is not set up, even though (it seems) the > list root element has been correctly matched. But when I add > the /list to the document() call, the parameter is correctly set up. The document() function returns a root node (don't confuse this with the outermost element node, which is sometimes referred to as the root element or document element). So the call on xsl:apply-templates will result in the template for the root node being called, with parameters. You've provided no explicit template for the root node, so the built-in template gets called. The built-in template does a call on <xsl:apply-templates/> for its children, i.e. for the <list> element, but without supplying any parameters. So your match="list" template rule gets called without parameters. To get the parameters through, you either have to bypass processing the root node, or you have to process it using a template that passes the parameters on. Mike Kay XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: apply templates with with-param, petermarshall | Thread | RE: apply templates with with-param, Linda van den Brink |
Applying a stylesheet to a styleshe, Matt Watson | Date | RE: apply templates with with-param, Linda van den Brink |
Month |