Re: UTF-8 POST request results in corrupted data

2008-10-12 Thread Andre-John Mas
On 7-Oct-08, at 07:02 , Mark Thomas wrote: Andre-John Mas wrote: Thanks for the answer on this point. Reading section 3.7.1 of RFC 2616 indicates that request can specify a character other than the default. For this reason the following should technically be legal: What I see, from test

Re: UTF-8 POST request results in corrupted data

2008-10-07 Thread Mark Thomas
Andre-John Mas wrote: > Thanks for the answer on this point. Reading section 3.7.1 of RFC 2616 > indicates that request can specify a character other than the default. > For this reason the following should technically be legal: > > enctype="application/x-www-form-urlencoded; charset=utf-8" > acc

Re: UTF-8 POST request results in corrupted data

2008-10-07 Thread Tim Funk
If you take that form and post it - how does the server know that the content is UTF-8? (Answer: it doesn't) The HTML directives tell the browser to encode everything into UTF-8 on the way to the web server. But there is nothing that tells the webserver explicitly what the charset is of the in

Re: UTF-8 POST request results in corrupted data

2008-10-06 Thread Andre-John Mas
Thanks for the answer on this point. Reading section 3.7.1 of RFC 2616 indicates that request can specify a character other than the default. For this reason the following should technically be legal: What I see, from testing on my Mac, is that Firefox and Safari fail to pass the charset

Re: UTF-8 POST request results in corrupted data

2008-10-06 Thread William A. Rowe, Jr.
Andre-John Mas wrote: > Just to repeat what I stated in the ticket: > > The problem I have with the suggested approach is that it treats UTF-8 > as an > exception, rather that a norm for my whole application server. I am not > sure > that I should be having to be specifying the encoding before han

Re: UTF-8 POST request results in corrupted data

2008-10-06 Thread Andre-John Mas
Just to repeat what I stated in the ticket: The problem I have with the suggested approach is that it treats UTF-8 as an exception, rather that a norm for my whole application server. I am not sure that I should be having to be specifying the encoding before handling every request. For a we

Re: UTF-8 POST request results in corrupted data

2008-10-06 Thread Tim Funk
Before reading the POST body - you should first be doing this: request.setCharacterEncoding("UTF-8") -Tim André-John Mas wrote: Hi, I have opened issue 45957, for an issue that has bothered me for a while: https://issues.apache.org/bugzilla/show_bug.cgi?id=45957 To resume: Currently in Tom