At 18:44 30/01/2002 -0800, Scott Ellsworth wrote:

>In other words, @cvs.packages is getting replaced just fine, but in the 
>process, all of my ANT variables are getting vaporized.

You're running afoul of a useful "feature" of XSLT.

Realising that creating attribute values dynamicly would be a common event, 
the designers provided a shortcut.

Instead of having to write

<outputNode>
   <xsl:attribute name="foobar">
     <xsl:value-of select="myExpression"/>
   </xsl:attribute>
</outputNode>

you can write this

<outputNode foobar="{myExpression}"/>

In your original template, this line

<cvs cvsroot="${cvs.root}" ...

is handled by the stylesheet extracting {cvs.root}, evaluating the 
expression and replacing it with the appropriate content.

Instead, you could use an expression giving ${cvs.root} as the result; I 
think this should work:

<cvs cvsroot="{'${cvs.root}'}" ...

Ie the cvsroot attribute is to contain the results of evaluating the 
expression '${cvs.root}', which is simply a string constant.


Hope this helps,
Bevan.


--
"Programming is an Art Form that Fights Back"

Bevan Arps (<mailto:[EMAIL PROTECTED]>[EMAIL PROTECTED])
Senior OO Analyst, ACT Financial Systems

This communication  is confidential  to ACT  Financial  Systems  (Asia 
Pacific)  and is intended for  use only by the  addressee.   The  views and 
opinions  expressed in  this email  are the senders  own and do not 
represent  the  views  and  opinions of  ACT  Financial  Systems  (Asia 
Pacific).

Reply via email to