this is a german Web-Mirror of MHONARC.ORG powered by Domainunion AG

xsl-list
[Top] [All Lists]

Re: [xsl] Dynamically determine which XSLT files to include and import?

2013-07-29 10:46:37
On 29 July 2013 16:34, Costello, Roger L. <costello(_at_)mitre(_dot_)org> wrote:
Hi Folks,

Is there a  way for an XSLT program to, at runtime, decide which XSLT files 
to include and import?

I imagine something like this at the top of the XSLT program:

    if the input file has value X set then
        include A.xsl, B.xsl
    else
        include C.xsl, D.xsl

Any way to do this?

No, it's not possible.  The typical solution is the "specific imports
common" design where the calling language decides which specific xslt
to run based on X.

However, if X is taken from the source message itself, then you can
just include all the XSLTs and use modes (or other techniques) to
control the processing flow.

-- 
Andrew Welch
https://andrewjwelch.com

--~------------------------------------------------------------------
XSL-List info and archive:  https://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: https://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--