Re: [xsl] news

Subject: Re: [xsl] news
From: Jeni Tennison <mail@xxxxxxxxxxxxxxxx>
Date: Mon, 19 Feb 2001 16:03:44 +0000
David Carlisle wrote:
>> What if the variable may, or may not, be defined as a global variable in a
>> stylesheet which imports or includes the stylesheet you are writing?
>
> Despite the fact that people ask for the feature,
> xsl:include/xsl:import may not be controlled at runtime, so you
> still know when writing a stylesheet whether or not a global
> variable is declared. If it is declared in a stylesheet that you
> have imported/included, then it is declared. If it is not declared
> in a stylesheet that you have imported/included then it is not
> declared.

But if you're writing the stylesheet that's being imported/included,
then you don't know what it's (going to be) imported/included into.  I
think that's what Dylan's talking about.

Dylan, I'd declare the variable in the stylesheet you're writing, but
with a nonsensical or otherwise unique value, and then test the value
of the variable - if it's that value, then you know the
importing/including stylesheet hasn't overridden (declared) it.

I hope that helps,

Jeni

---
Jeni Tennison
http://www.jenitennison.com/



 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread