Yukihiro Matsumoto
7/5/2007 4:42:00 PM
Hi,
In message "Re: Bug in CGI::unescapeHTML?"
on Thu, 5 Jul 2007 13:00:02 +0900, Esad Hajdarevic <esad.talks@esse.at> writes:
|I think there's a bug in CGI::unescapeHTML. Or am I doing something wrong?
|
|$KCODE='u'
|CGI::unescapeHTML("ã")
|
|will return "\343", which according to my screaming mysql utf-8 encoded
|database is not a valid utf-8 sequence
Not a bug, unfortunately. Since your client sent a binary sequence
"\343" in URL encoding, unescapeHTML() decoded it back. Specifying
$KCODE='u' does not affect encoding your clients send. You have to
check (or convert) input from your clients explicitly, anyway.
matz.