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

RE: Running XSL through StylusStudio

  • To: "'Jeff Sese'" <jsese@a...>,<xml-dev@l...>
  • Subject: RE: Running XSL through StylusStudio
  • From: "Michael Kay" <mike@s...>
  • Date: Thu, 16 Mar 2006 10:13:30 -0000
  • In-reply-to:
  • Thread-index: AcZInCZ5Kn6w5yasQ4WSyEaZO3z18AARaEBg

xsl through xml
Check using system-property('xsl:product-version') which version of Saxon is
being used in each case.

You're in a fairly subtle area of the spec here - one which is actually
going to change in detail in the final Rec. The rules say that a character
affected by character maps shouldn't be escaped, and the question is whether
replacing an ampersand by an ampersand "affects" the character. Because this
is an edge case, there may well be differences between Saxon versions.

Michael Kay
http://www.saxonica.com/

> -----Original Message-----
> From: Jeff Sese [mailto:jsese@a...] 
> Sent: 16 March 2006 01:52
> To: xml-dev@l...
> Subject:  Running XSL through StylusStudio
> 
> Hi, I’m running an xsl using stylusstudio and I’m having a 
> different output
> compared to the one I get running saxon using the command line.
> 
> I have an xsl that uses a character-map which simply escapes 
> the ampersand
> character.
> 
> <?xml version='1.0'?>
> <xsl:stylesheet version="2.0"
> xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
> <xsl:character-map name="map">
> 	<xsl:output-character character="&#x26;" string="&#x26;"/>
> </xsl:character-map>
> <xsl:output method="xml" encoding="UTF-8" use-character-maps="map"/>
> <xsl:template match="/">
> 	<xsl:apply-templates/>
> </xsl:template>
> <xsl:template match="*">
> 	<xsl:copy-of select="."/>
> </xsl:template>
> </xsl:stylesheet>
> 
> And using this xml as source:
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <root>
> <data>&#x26;test;</data>
> </root>
> 
> Using saxon in the command line I get:
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <root>
> <data>&test;</data>
> </root>
> 
> But using stylusstudio (using saxon as the xslt processor) I get this:
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <root>
> <data>&amp;test;</data>
> </root>
> 
> What seem's to be the problem here???
> 
> Jeff Sese
> 
> 
> 
> 
> -----------------------------------------------------------------
> The xml-dev list is sponsored by XML.org <http://www.xml.org>, an
> initiative of OASIS <http://www.oasis-open.org>
> 
> The list archives are at http://lists.xml.org/archives/xml-dev/
> 
> To subscribe or unsubscribe from this list use the subscription
> manager: <http://www.oasis-open.org/mlmanage/index.php>
> 
> 



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
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

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.