Altova Mailing List Archives>Archive Index >microsoft.public.xsl Archive Home >Recent entries >Thread Prev - Creating a dynamic element name from one of its children elements [Thread Next] Re: Creating a dynamic element name from one of its children elementsTo: NULL Date: 12/12/2007 8:23:00 AM
"brc" <brentc@a...> wrote in message
news:f5d18c38-70dd-4248-8b03-471c5eaed482@i......
>I want to set the name of an element to the value of one of its child
> elements (the 'name' element) in a XSL stylesheet. See below.
>
> <xsl:template match="ns:well">
> <xsl:element name="{?????}">
> <ns:name><xsl:value-of select="ns:name"/><ns:name>
> <ns:wellType><xsl:value-of select="ns:wellType"/>
> .
> .
> .
> </xsl:element>
> </xsl:template>
>
> So what do I need to substitute for the ????? so that the elements
> name will be set to
> the name of the "name" element it includes?
Seems a strange request, but why can't you use the following?
<xsl:element name="{ns:name}">
--
Joe Fawcett (MVP - XML)
http://joe.fawcett.name
| ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
