XSLT processing corrupts character encoding

Subject: XSLT processing corrupts character encoding
From: Christian Mallwitz <c.mallwitz@xxxxxxxxxxxx>
Date: Wed, 2 Feb 2000 21:38:45 +0100
Hi folks,

In a very simple example I want to change XML tag names from 'persons' and
'person' to 'humans' and 'human' respectively. The XML and XSLT file are
attached. Both are UTF-8 encoded - the XML file containing German Umlauts
and an Euro currency symbol as an example. Additionally I have attached the
result file. 

After Processing the tag names are changed correctly but the encoding was
corrupted as the result file is NOT UTF-8 encoded. The German Umlauts are
ISO-8859-1 encoded while the Euro symbol is included as character reference
(which is correct but not intended). 

Can anybody tell me if my XML or XSLT file are not correct? 

I'm using JDK1.2.2/Xerces-1.0.1/Xalan-0.19.2 for processing the files as in:
java org.apache.xalan.xslt.Process -IN encoding-test.xml -XSL
encoding-test.xslt -OUT encoding-test-out.xml

Thanks in advance
Christian

BTW: If I choose HTML as output methode the German Umlauts appear as HTML
names entities and the Euro symbol is complete rubish ...
-- 
Christian Mallwitz INTERSHOP Communications Germany
Senior Software Engineer    phone: +49 3641 894 334

Attachment: encoding-test.xml
Description: Binary data

Attachment: encoding-test.xslt
Description: Binary data

Attachment: encoding-test-out.xml
Description: Binary data

Current Thread