Chapter 6 HTTP Requests and Header Settings

HTTP Header Settings

HTTP Encoding Header Setting

The encoding header controls language and character settings related to localization.

Accept-Language

Cisco Unified IP Phones populate the Accept-Language HTTP request header in compliance with the HTTP specification.

For example, the Accept-Language value advertised by a phone configured for the

English_United_States user locale would look like:

Accept-Language: en-US

Accept-Charset

As of this release, the phones are capable of handling UTF-8 encoding and, depending on phone model, some degree of Unicode support.

The phone models (such as the 7940, 7960, 7905 and 7912) can handle UTF-8 encoding, but will only recognize characters which can be represented by the default encoding of the phone's current user locale. For example, if the phone is currently configured to use the English_United_States locale, then it will only be able to display UTF-8 characters which map to the ISO-8859-1 character set.

The phone models (such as the 7970, 7971, 7941, 7961, and 7911) provide UTF-8 and true Unicode support. These phones provide support for more multi-byte character sets and user locales like Japanese and Chinese.

In addition to the character set for the currently configured user locale, the new phone models will also support ISO-8859-1 characters in their font files.

All phones will advertise their supported encodings using the standard HTTP Accept-Charset header. Per HTTP standard, q-values are used to specify preferred encodings. The older phone models, with more limited UTF-8 support, will specify a lower q-value for UTF-8 than the default user locale encoding.

For example, an older phone model configured with the English_United_States user locale would include an Accept-Charset header similar to the following:

Accept-Charset: iso-8859-1, utf-8;q=0.8

A newer phone model with Unicode support would advertise an Accept-Charset similar to the following:

Accept-Charset: utf-8,iso-8859-1;q=0.8

HTTP Response Headers: Content-Type

Because the phones are capable of supporting multiple character encodings, HTTP responses returned to the phones should include the 'charset' parameter on the HTTP Content-Type header. Examples of responses including the “charset” parament are shown below:

Content-Type: text/xml; charset=ISO-8859-1

Content-Type: text/xml; charset=UTF-8

Content-Type: text/plain; charset=Shift_JIS

HTTP standards state that if the encoding is not explicitly specified, ISO-8859-1 is the default.Cisco Unified IP Phones are typically compatible with this spec, but not fully compliant.

Cisco Unified IP Phone Services Application Development Notes

6-6

OL-20949-01

 

 

Page 74
Image 74
Cisco Systems OL-20949-01 manual Http Encoding Header Setting, Accept-Language