This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
ref:Jarno Elovirta Re: RE: Filtering elements of a tree
- From: "william locksman" <vsd18 at rediffmail dot com>
- To: xsl-list at lists dot mulberrytech dot com
- Date: 8 May 2002 14:58:18 -0000
- Subject: ref:Jarno Elovirta Re: RE: [xsl] Filtering elements of a tree
- Reply-to: xsl-list at lists dot mulberrytech dot com
hi jarno..
please forgive me for my ignorence.. can you throw some light on
the following two expressions which you have made use
1. <xsl:copy-of select="@*" />
2. <xsl:apply-templates select="*[@id = '7' or
descendant::*/@id = '7']"/>
can you please explain me what the above two statements does..
sorry abt this ... but i found it important to ask u this
question
thanks
>On Wed, 08 May 2002 Jarno.Elovirta@nokia.com wrote :
>>Heppa,
>>
>> > I want to select the element artist with id=7 and its
>>parent,
>> > grand parent and so on.
>> > After transformation the xml should look like this-
>> >
>> > <TreeNode id="5" Text="music">
>> > <TreeNode id="6" Text="blues">
>> > <TreeNode id="7" Text="bb king"/>
>> > </TreeNode>
>> > <TreeNode id="6" Text="jazz">
>> > <TreeNode id="11" Text="bebop">
>> > <TreeNode id="7" Text="charlie parker"/>
>> > </TreeNode>
>> > <TreeNode id="7" Text="miles davis"/>
>> > </TreeNode>
>> > </TreeNode>
>>
>><xsl:template match="*">
>> <TreeNode>
>> <xsl:copy-of select="@*" />
>> <xsl:apply-templates select="*[@id = '7' or
>>descendant::*/@id = '7']"/>
>> </TreeNode>
>></xsl:template>
>>
>>There are better solutions,
>>
>>Santtu
>>
>> XSL-List info and archive:
>>http://www.mulberrytech.com/xsl/xsl-list
>>
>
>_________________________________________________________
>Click below to visit monsterindia.com and review jobs in India or
>Abroad
>http://monsterindia.rediff.com/jobs
>
>
>XSL-List info and archive:
>http://www.mulberrytech.com/xsl/xsl-list
>
_________________________________________________________
Click below to visit monsterindia.com and review jobs in India or
Abroad
http://monsterindia.rediff.com/jobs
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list