I have an interesting problem with UTF-8 charset and Apache::ASP (possibly):

I had to construct some xml with Apache::ASP some time ago, but due to a switch, I now want the resulting file to be UTF-8 encoded instead of ISO-8859-7 that it was until now.
This is all fine, however the data I'm reading from the database are also in ISO-8859-7.
So I used Script_OnFlush like this:


$$ref =~ s|([\xB8-\xFE])|chr(ord($1)+0x02D0)|sge;
(BTW I also tried ``use Encode;'' and ``use encoding "iso-8859-7";'' of perl-5.8 with quite the same results)
in order to convert all greek characters from iso-8859-7 to utf-8 just before flushing the output to the client.


The problem is that although I can verify that $$ref contains what I want (I also printed it to a file just to make sure), the output to any client (Mozilla, Opera, IE, XML Spy, whatever) is truncated and obviously not valid.
I've actually used Ethereal to sniff the data on the network and they seem to be valid and the charset checks out ok.


Anyone have an idea what might be wrong ?


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to