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

RE: converting escaped values to literal for text outp

Subject: RE: converting escaped values to literal for text output
From: Jarno.Elovirta@xxxxxxxxx
Date: Tue, 20 Jan 2004 14:42:01 +0200
xml escape values
Hi,

> What is the best way to convert xml escape values like `&',
> `Á' etc to their literal values for text output.

An XML parser.

> I need this method for my own stylesheet which I use to convert 
> proprietary XML to text.

Ah, so you want to write an XML parser with XSLT. There are extension function in some XSLT engines that allow you to call an XML parser on a string and get a source tree back, suggest you use those if you need to process looks-like-XML-but-is-not-XML. Make sure, thought, that the string you pass to the extension method really is XML, it will choke on it if it's not well-formed. Another approach is to preprocess the XML before feeding it to the XSLT engine, with e.g. a SAX filter, that will unescape your pseudo-XML into XML.

Cheers,

Jarno - Velvet Acid Christ: The Hand (cut Throat Psycho Rave Mix)

 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.