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

RE: encoding issues

Subject: RE: encoding issues
From: "Andrew Welch" <awelch@xxxxxxxxxxxxxxx>
Date: Wed, 3 Jul 2002 12:43:13 +0100
160 encoding issue
David:
>But to get the html browser to detect the right encoding you need to
add
>a meta element to the head, the html output method does that
>automatically but in XML you need to do it by hand

Julian:
>IE either supports XML (+CSS) (so the HTML engine won't
>even look at it), *or* HTML. If you're producing HTML, the XML
declaration
>is irrelevant (the only thing that counts are the encoding declaration
from
>the HTTP response and/or the META tag in the HTML).

Ahaaa, so if I use the xml output method with xhtml doctypes, coupled
with a hand coded <meta> tag I can get xhtml output thats decoded in
unicode.  After testing - this works fine for me, is it ok?

David:
>(which is a bit risky
>in general as you can not be sure that teh system will use the encoding
>you ask for)

How can you be sure?  Is it the case that you cant be sure they will
have it installed?  In which case, with utf-8 Im pretty safe?

(thanks for all the responses)

cheers
andrew


-----Original Message-----
From: David Carlisle [mailto:davidc@xxxxxxxxx]
Sent: 03 July 2002 12:21
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re:  encoding issues



> True, but &#160; is a non-breaking-space in anyones markup.
Yes but that's what's in teh input, but it isn't like that in the output
it apears as character data:

#160 is two bytes in utf-8 so if you read those two bytes as latin-1 you
will see two characters, the first being an accented A.

An alternative to utf-8 if you don't want utf-16 is us-ascii
then #160 would be output as &#160; and would, as you say,
be understood in any encoding.

But to get the html browser to detect the right encoding you need to add
a meta element to the head, the html output method does that
automatically but in XML you need to do it by hand (which is a bit risky
in general as you can not be sure that teh system will use the encoding
you ask for)

David

_____________________________________________________________________
This message has been checked for all known viruses by Star Internet
delivered through the MessageLabs Virus Scanning Service. For further
information visit http://www.star.net.uk/stats.asp or alternatively call
Star Internet for details on the Virus Scanning Service.

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





---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.350 / Virus Database: 196 - Release Date: 17/04/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.350 / Virus Database: 196 - Release Date: 17/04/2002
 

 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.