Sun Java System Web Server 6.1 SP7 Programmer's Guide to Web Applications

Servlets

This section describes how the Sun Java System Web Server determines the character encoding for the servlet request and the servlet response.

For encoding, see http://java.sun.com/j2se/1.4.2/docs/guide/intl/encoding.doc.html

Servlet Request

When processing the servlet request, the server uses the following order of precedence, first to last, to determine the character encoding for the request parameters:

Servlet Response

When processing a servlet response, the server uses the following order of precedence, first to last, to determine the response character encoding:

To specify the character encoding that should be set in the Content-type header of the response if the response locale is set using the ServletResponse.setLocale method. You can use the locale-charset-map under the locale-charset-info element in the sun-web.xml file. For more information about this element, seelocale-charset-info