• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

XML to XML using XSLT

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

i have written a xsl for converting xml to another xml but am getting the same xml in the output xsl is not getting applied .
can anybody look into this??

xml
---
<?xml version="1.0" ?>
<?xml-stylesheet type="text/xml" href="LoiCheckXSL.xsl"?>
<XEC.root>
<XEC.child>
<XEC.imagelink>
<XEC.caption>caption</XEC.caption>
<XEC.pagenumber>18</XEC.pagenumber>
<XEC.imagetype>type</XEC.imagetype>
</XEC.imagelink>
</XEC.child>
</XEC.root>

xsl
---
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:fo="http://www.w3.org/1999/XSL/Format">
<xsl utput method="xml" indent="yes"/>
<xsl:template match="/">
<xsl:apply-templates />
</xsl:template>

<xsl:template match="XEC.child">
<xsl:for-each select="./*">
<font color="red"><xsl:value-of select="node()[1]" /></font><br/>

</xsl:for-each>
</xsl:template>

</xsl:stylesheet>
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic