-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Thomas,

Thomas Peter Berntsen wrote:
>> Are you serving your pages in UTF-8 encoding? Usually, the browser uses
>> the response encoding from the previous request to submit the next
>> request's URI. If you are using ISO-8859-1 for your web pages, then
>> expecting the browser to use UTF-8 for the URIs in incorrect.
> 
> Thanks. I'll check that. But isn't that irrelevant in the case that I
> just request a directory listing through a URL like:
> "localhost:8080/test"? Or irrelevant in the case I request a file
> directly through a URL like: "localhost:8080/æøå.gif"?

Since the server doesn't know for sure what encoding is being used by
the browser, it certainly does make a difference. If the browser uses
the encoding from the last response, then the encoding from the last
response is certainly relevant.

If you cold-call the server with a URL, the server does not know what
encoding to use. I believe that Tomcat's default is ISO-8859-1 (as
inferred from
http://java.sun.com/developer/technicalArticles/Intl/HTTPCharset/index.html,
which points out the use of URIEncoding in the <Connector>), in spite of
the W3C's recommendation to use UTF-8
(http://www.w3.org/TR/html40/appendix/notes.html#non-ascii-chars).

> Just to be sure I edited the index.jsp of the ROOT app in which I have
> created the "æøå.gif" file and changed the encoding to UTF-8, but with
> no different result.

Hmm... and did you still have URIEncoding="UTF-8" set in your
<Connector>? Also, make sure that it's the right connector... Tomcat's
default config file has a bunch of connectors that are commented-out.

- -chris

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGAbN09CaO5/Lv0PARAu9pAJwNwi3G/2j/P+ygJqjiHE0lj4IjAwCgiPgm
b3KRLBeQc0h7E9b5SDyQPa8=
=26jP
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to