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

Re: Unparsed-text and character conversion

Subject: Re: Unparsed-text and character conversion
From: David Carlisle <davidc@xxxxxxxxx>
Date: Fri, 7 Jan 2005 17:53:45 GMT
iso 8859 1 conversion
If your file is EBCDIC then you shouldn't declare the encoding as
latin 1:
'iso-8859-1'

You could declare it as EBCDIC but then there's no guarantee that the
system will understand that. (Althouggh it's not guaranteed to
understand iso-8859-1 either).

probably Michael will tell you adding a new supported encoding only
means writing half a line of java and compiling some new class
somewhere, but personally I'd probably cheat and read it as latin 1 as
you have and then use translate() or replace() to fix up the EBCDIC
to iso-8859-1 conversion:


   <xsl:variable name="input-text" as="xs:string"
select="translate(unparsed-text($input, 'iso-8859-1'), 'ebcdic codes',
'ascii codes')"/>

David

________________________________________________________________________
This e-mail has been scanned for all viruses by Star. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________

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.