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

RE: Is it possible to get " " in output rather th

Subject: RE: Is it possible to get " " in output rather than the encoded character?
From: "Steven Reddie" <smr@xxxxxxxxxxxxxx>
Date: Thu, 20 May 2004 00:24:12 +1000
xsl output nbsp
I've taken the XmlTextWriter out of the picture and am now accessing the
byte[] output stream directly.  I think what I'm seeing is a misbehaving
processor, but being new to this I'm not certain.  The XSL and XML files are
included below.  Here is the output of the processor with non-printable
bytes output in \xAA format:

Output when xsl:output encoding="iso-8859-1":
	<html>\x0Ahello_\xA0_world\x0A</html>

Output when xsl:output encoding="utf-8":
	\xEF\xBB\xBF<html>\x0Ahello_\xC2\xA0_world\x0A</html>

---------- test.xsl ----------
<?xml version="1.0" encoding="iso-8859-1"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">

<xsl:output method="html" version="1.0" encoding="iso-8859-1" indent="yes"/>

<xsl:template match="/">
<html>
hello_&#160;_world
</html>
</xsl:template>

</xsl:stylesheet>
------------------------------

---------- test.xml ----------
<?xml version="1.0" encoding="iso-8859-1"?>
<?xml-stylesheet type="text/xsl" href="test.xsl"?>
<bookmarks>
</bookmarks>
------------------------------

Having access to the byte stream I can obviously translate non-printable
character to &#000; format, but I thought that the whole point of the
xsl:output encoding was so that this would be done automatically?  Have I
got any of this wrong?

Regards,

Steven

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.