Hi:
I am having some difficulty with UTF-8 encoded
chracaters in Java.
My XML has a question which has cyrillic characters. My Java
servlet renders this as HTML with a form for the reply.
The HTML produced
displays OK in the browser (the response type on the
Java servelet has to be set to "text/html;
charset=UTF-8" for this to work).
I have to send cyrillic characters back in the
response to the question, in a text field on the form.
The browser is sending back a byte stream (which I am
printing here as hex): d0b3d0bed180d0bed0b4 (this is a
cyrillic
word correctly coded as utf-8).
However, on collecting the response (using
request.getParameterValues(fieldname))the servlet
returns the byte stream: d0b3d0bed13fd0bed0b4.
A mistake in the fifth byte!
Has anyone heard of this problem? I suspect the
problem is in the JAVA UTF-8 converter.
Regards
Graham