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

RE: Correcting an XML document

Subject: RE: Correcting an XML document
From: walter.crockett@xxxxxxxxxxxxxxxxxxxxx
Date: Fri, 16 Jul 2004 13:32:48 -0400
xml timestamp datatype
Here's the full text of the XSL document, whose purpose is to change the
value of all Datatype elements whose value is DATE to a value of TIMESTAMP,
and then produce a full corrected XML document, tags and all. I'm using XML
SPY and applying this XSL to the original XML document. The output I get,
however, is just a mass of values, without tags. 
 

<?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" version="1.0" encoding="UTF-8"
indent="yes"/>
	
<xsl:template match="*">
<xsl:copy><xsl:copy-of select="@*"/><xsl:apply-templates/></xsl:copy>
</xsl:template>

<xsl:template match="Datatype[.='DATE']">
<Datatype>TIMESTAMP</Datatype>
</xsl:template>

</xsl:stylesheet>


-----Original Message-----
From: Michael Kay [mailto:mhk@xxxxxxxxx]
Sent: Friday, July 16, 2004 11:17 AM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: RE:  Correcting an XML
documentxsl-list@xxxxxxxxxxxxxxxxxxxxxx


>  I get all the values in the document, but none of the XML 
> tags. I need to
> reproduce the entire XML document, tags and all, with the 
> changes in it.
> 
> Am I missing something simple?

Probably, but from the info given, I've no idea what it is. Please supply
more details of what you are doing, so we can see what you're doing wrong.

Michael Kay

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

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.
Email
First Name
Last Name
Company
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.