[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Newbie wants comments too . . .

Subject: Newbie wants comments too . . .
From: Frank Merrow <fmerrow@xxxxxxxxxxxx>
Date: Wed, 07 May 2008 13:45:18 -0700
 Newbie wants comments too . . .
So I am very new to XSL and teaching myself as I go.

I am trying to transform and existing XML database to a new format.

The scrips works (see below), EXCEPT comments in the original file are not copied into the output file.

The individual database items are converted as I want them, but the comments are lost.

What do I need to do so that the original file comments also get copied to the output file?


<?xml version="1.0" encoding="UTF-8"?>

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="xml"/>
<xsl:preserve-space elements="*"/>
<xsl:template match="/">
<xsl:for-each select="AsiaInfoDb/*">
<aitag><xsl:copy-of select="@*"/><xsl:attribute name="id"><xsl:value-of select="name()"/></xsl:attribute><xsl:value-of select="."/></aitag><xsl:text>

Current Thread


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.