views:

993

answers:

2

It seems I cannot get UTF-8 encoding to be sent in the response headers. I tried using this to no avail:

resp.setHeader("Content-Encoding", "utf-8");

Does anyone know when is this bug to be fixed or is there a workaround?

References:

+4  A: 

Per the w3 reference, Content-Encoding is for such things as gzip, deflate, compress -- not for "how is Unicode encoded in the body". What you need is e.g.

Content-Type: text/html; charset=utf-8

i.e., the charset attribute of Content-Type.

Alex Martelli
A: 

Content-Encoding set the content encoding for example gzip...

vhly