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

XML -> XHTML with UTF-8 escaping pass-thru

Subject: XML -> XHTML with UTF-8 escaping pass-thru
From: Gan Uesli Starling <alias@xxxxxxxxxxx>
Date: Fri, 21 Mar 2003 10:46:45 -0500
utf 8 escaping
Howdy,

I have an XML here...

http://starling.ws/XML/howto.xml

...which uses this XSLT...

http://starling.ws/XML/howto.xsl

...and looks fine when viewed in either
Mozilla 1.2.1 or MSIE 6 SP 1 as *.xml.

But when I use that same XSLT to output
to *.html as a file, then go to view it
as *.html with those same browsers then
the UTF-8 (since it is not escaped with
ampersand-pound) does not display for folks
not-in-the-know enough to re-set their
encoding. Plus it is a hassle for them so
that I fear they won't bother.

The result for them comes out like this...

http://starling.ws/XML/howto.html

...and does not look as well even though
it is the same contents (because of the
default encoding for those browsers). All
the nbsp's and arrow buttons get trashed.

But it would work even for them if the *.html
output retained the ampersand-pound escaping
for these UTF-8 chars, would it not? At least
I have seen it to work that way at this URL
on those same browsers...

http://esperanto.us

Is there a way to get my XSLT to pass
those escaped UTF-8 chars thru without having
to maintain two versions of the original XML?

That is to say, when the XSLT finds an &#160;
in the XML, that the output HTML would contain
ampersand-pound one-sixty semicolon?

If it proves to be a major pain for XSLT,
then perhaps I'll have to ex-post-facto
filter with Perl.

TIA,

Gan

--

Mistera Sturno - Rarest Extinct Bird

 <(+)__       Gan Uesli Starling
  ((__/)=-    Kalamazoo, MI, USA
   `||`
    ++        http://starling.us


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.