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

RE: data vs. xml

Subject: RE: data vs. xml
From: "Michael Kay" <mhk@xxxxxxxxx>
Date: Fri, 4 Apr 2003 16:15:05 +0100
xb0
> I modified the xml generator to include <![CDATA[ ]]> 
> elements.  However,  I also found that some of my data 
> contains RTF characters (i.e. \x093, \x096, \xB0).  I believe 
> this is a result of a copy and paste from MSWord into the 
> database program, and it is not an easy thing to fix as the 
> database contains tens of thousands of entries.  I also 
> noticed that the XSLT processor (instant saxon) still had 
> difficulty accepting a <![CDATA[ ]]> node that contained one 
> of the above characters.  My understanding is that the data 
> found within the <![CDATA[ ]]> should be considered just 
> that: data.

A CDATA section must contain legitimate XML characters.

I suspect that your problem is that your XML source file has no encoding
declaration, so the encoding is defaulting to UTF-8, and an octet such
as xB0 is not a valid UTF-8 encoding of any XML character.

You should specify the actual encoding of the XML file in an XML
declaration at its start. Your encoding is probably cp1252. Then you
need to parse it using an XML parser that recognizes this encoding. XML
parsers are not required to support any encodings other than UTF-8 and
UTF-16.

Michael Kay
Software AG
home: Michael.H.Kay@xxxxxxxxxxxx
work: Michael.Kay@xxxxxxxxxxxxxx 


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


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.