Sun Java System Application Server Platform Edition 8.1 2005Q2 Update 2 Developer's Guide

- Previous: locale-charset-info
- Next: localpart

## locale-charset-map

Maps locales and agents to character encodings. Provided for backward compatibility. Used only for request processing. Used only if the character encoding is not specified in the request and cannot be derived from the optional parameter-encoding element. For encodings, see `http://java.sun.com/j2se/1.4/docs/guide/intl/encoding.doc.html`.

### Superelements

locale-charset-info (`sun-web.xml`)

### Subelements

The following table describes subelements for the `locale-charset-map` element.

Table A–55 `locale-charset-map` Subelements

Element | Required | Description
--- | --- | ---
description | zero or one | Specifies an optional text description of a mapping.

### Attributes

The following table describes attributes for the `locale-charset-map` element.

Table A–56 `locale-charset-map` Attributes

Attribute | Default | Description
--- | --- | ---
`locale` | none | Specifies the locale name.
`agent` | none | (optional) Specifies the type of client that interacts with the application server. For a given locale, different agents can have different preferred character encodings. The value of this attribute must exactly match the value of the `user-agent` HTTP request header sent by the client. See Table A–57 for more information.
`charset` | none | Specifies the character encoding to which the locale maps.

### Example Agents

The following table specifies example `agent` attribute values.

Table A–57 Example `agent` Attribute Values

Agent | `user-agent` Header and `agent` Attribute Value
--- | ---
Internet Explorer 5.00 for Windows 2000 |
    Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)
Netscape 4.7.7 for Windows 2000 |
    Mozilla/4.77 [en] (Windows NT 5.0; U)
Netscape 4.7 for Solaris |
    Mozilla/4.7 [en] (X11; u; Sun OS 5.6 sun4u)

- Previous: locale-charset-info
- Next: localpart

- © 2010, Oracle Corporation and/or its affiliates