xsl-list
[Top] [All Lists]

RE: RE: How to transform an embedded node into text

2005-09-26 01:03:28
Try:

<xsl:template match="short/parameter">%s</xsl:template>

and

<xsl:template match="short">
 <xsl:copy>
  <xsl:apply-templates/>
 </xsl:copy>
</xsl:template>

Michael Kay
http://www.saxonica.com/ 

-----Original Message-----
From: Meyer, Roland [mailto:roland(_dot_)meyer(_at_)siemens(_dot_)com] 
Sent: 26 September 2005 08:45
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: [xsl] RE: How to transform an embedded node into text

Hi,

I have to transform an XML file into another one and have the 
following
problem. The source XML looks like this:

<root>
<short>Some text.
      
Description for the next node: <parameter id="8"
value="bldInvntryBladeIndex"/> 
Some other text <parameter id="9" value="trapVbPrimaryBladeIndex"/> 
And again some different text: <parameter id="10"
value="stm1CfgStm1Index"/>
</short>
</root>


The destination XML file should look like:

<root>
<short>Some text.
      
Description for the next node: %s 
Some other text %s 
And again some different text: %s
</short>
</root>


Is there a way to transform the "parameter" nodes in the embedded text
of node "short" into another text?


Best Regards,
Roland 



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





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



<Prev in Thread] Current Thread [Next in Thread>