Subject: RE: [xsl] alternative for modes From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx> Date: Thu, 12 Feb 2004 14:27:10 -0500 |
<xsl:variable name="general-result"> <xsl:call-template name="general"/> </xsl:variable>
<xsl:apply-templates select="child[$condition1]" mode="condition1"/> <xsl:apply-templates select="child[$condition2]" mode="condition2"/>
Cheers, Wendell
This is not possible I think, since the general template calls the other template on a particular order (based on the calculation in the general template), so I don't think it's possible in this situation.
Thanks for the tip,
Peter
-----Original Message----- From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx [mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of Jeni Tennison Sent: donderdag 12 februari 2004 12:41 To: Peter Billen; xsl-list@xxxxxxxxxxxxxxxxxxxxxx Subject: Re: [xsl] alternative for modes
Hi Peter,
> As I mentioned above, 'generalTemplate' can be called on several > places in the template, because everytime I need the same > calculations, ... on the 'root'-tag. But each time (in every other > place), I actually need different manipulations on the 'child'-tag.
Just a thought, but depending on what the general template is doing, it might be that you can turn around the processing, so that instead of calling the general template with a parameter specifying the mode, you apply templates in the specific mode and those templates call the general template as appropriate to perform the necessary calculations.
Cheers,
Jeni
====================================================================== Wendell Piez mailto:wapiez@xxxxxxxxxxxxxxxx Mulberry Technologies, Inc. http://www.mulberrytech.com 17 West Jefferson Street Direct Phone: 301/315-9635 Suite 207 Phone: 301/315-9631 Rockville, MD 20850 Fax: 301/315-8285 ---------------------------------------------------------------------- Mulberry Technologies: A Consultancy Specializing in SGML and XML ======================================================================
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] alternative for modes, Peter Billen | Thread | RE: [xsl] alternative for modes, Peter Billen |
[xsl] Grouping problem, Uslu, Cihan Y (MED) | Date | [xsl] IBM releases free 2004 Middle, Frank Carlos |
Month |