my dog learned polymorphism*
The moose likes XML and Related Technologies and the fly likes How to write the xsl for this... Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "How to write the xsl for this..." Watch "How to write the xsl for this..." New topic
Author

How to write the xsl for this...

Avi Nash
Ranch Hand

Joined: Jul 17, 2003
Posts: 69
Hi all
How to write the xsl for this data in xml:
<Node>
<A>a1</A>
<B>b1</B>
<A>a2</A>
<B>b2</B>
<A>a3</A>
<B>b3</B>
.......
.......
</Node>
I want the output xml (after applying the xsl) to be:
<A>a1</A>
<B>b1</B>
<A>a2</A>
<B>b2</B>
<A>a3</A>
<B>b3</B>
........
........
Help required Imme. Thanks in advance.
-Avinash
Nimchi Yung
Ranch Hand

Joined: Jan 27, 2004
Posts: 71
Try this:
<?xml version="1.0" ?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform" >
<xsl utput method="xml" encoding="ISO-8859-1" indent="yes"/>
<xsl:template match="/Node/*">
<xsl:copy-of select="."/>
</xsl:template>
</xsl:stylesheet>

--Nimchi
 
jQuery in Action, 2nd edition
 
subject: How to write the xsl for this...
 
Similar Threads
How XSL Processor reads ???
Do you know how to write this drools?
the algrithm in my homework
[medium]Challenge the mathematicians
logic:iterate in struts