Subject: Re: [xsl] creating top-level elements from within child elements From: RQamar <qamar_rahil@xxxxxxxxxxx> Date: Tue, 22 Feb 2005 15:15:54 +0000 |
If I remember correctly you hadOh Im sorry but this has brought me back to our discussion yesterday where you said that a straight-forward way of making A1 and A2 siblings is to simply write
<A1> <xsl:apply-templates/> </A1>
which is an instruction to place the result tree fragment generated by applying templates as the child of an A1 element.
if you don't want the result to be placed as a child of A1 don't put it at that point in the stylesheet, place teh A1 element it in the stylesheet where you want it in the result, as a sibling of A2.
David
<A1> <xsl:apply-templates/> </A1> <A2> <xsl:apply-templates/> </A2>
------------------------------- The code below is for the benefit of Jarno and Omprakash who were confused about my requirement:
<PrimeConcept id="10180"> <PrimeName>Car</PrimeName> <SubConcepts> <SubConcept id="10298" name="Toyota"/> </SubConcepts> </PrimeConcept> </Top>
<PrimeConcept id='10180'>Car</PrimeConcept> <SubConcepts> <SubConcept id='10298'>Toyota</SubConcept> </SubConcepts>
Thanks all for responding. Rahil
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] creating top-level elemen, David Carlisle | Thread | Re: [xsl] creating top-level elemen, David Carlisle |
[xsl] using an attribute's value as, Jakob Fix | Date | RE: [xsl] using an attribute's valu, Michael Kay |
Month |