116 Part I: Core Ideas
User overrides thus become an unfortunate necessity for readers hoping to view the
content correctly.
Ajax applications are just as susceptible to developer ignorance of character encoding.
Given our shrinking world coupled with the increased audience applications may enjoy,
this is unacceptable. We present here only the briefest discussion of character sets and
encoding to assist Ajax-focused developers.
When selecting a data encoding format, you almost certainly should consider Unicode
encoding for all content. For Ajax developers, this will have to be UTF-8, and you’ll see why
in a brief moment. Regardless of the decision being forced upon us, the advantages of
adopting UTF-8 for your site or application are significant. First, numerous languages will
be able to be used across the site and within pages freely, including accepting data in forms.
Second, because of a standard encoding format for input and output, server-side code
should be simplified since it won’t be necessary to fork depending on the encoding format
received or sent. Finally, even if there is no current need to use other languages, the
application will be ready to do so immediately if the need arises.
English-speaking developers should be at least vaguely familiar with the ISO-8859-1
character encoding, as it is often included in XHTML pages in a <meta> tag like:
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
or in the response headers from the server.