You are viewing a plain text version of this content. The canonical link for it is here.
Posted to apreq-dev@httpd.apache.org by Joe Schaefer <jo...@mail.sunstarsys.com> on 2006/01/23 13:49:53 UTC
[Naoya Ito] Apache2::Request::param() BUG
To: Joe Schaefer
Hi, I'm Naoya Ito, Japanese Perl Programmer. (I'm sorry for my bad English.)
I found a problem when I was using your great library Apache2::Request.
The problem is that I can not retrieve a value of the parameter with param()
if the query string includes some escaped UTF-8 characters.
For example,
http://b.hatena.ne.jp/add?mode=confirm&title=asahi.com%uFF1A%u8F38%u5165%u725B%u8089%u306E%u5168%u91CF%u691C%u67FB%u300C%u7269%u7406%u7684%u306B%u4E0D%u53EF%u80FD%u300D%u3000%u8FB2%u6C34%u6B21%u5B98%u8868%u660E%A0-%A0%u66AE%u3089%u3057&url=http%3A//www.asahi.com/life/update/0123/003.html
This url contains 3 parameters, "mode" and "title" and "url", and some
escaped string which includes Japanese multibyte characters.
I could get "mode" parameter but I could'nt get "title" and "url."
When I changed order of parameters like this:
http://b.hatena.ne.jp/add?mode=confirm&url=http%3A//www.asahi.com/life/update/0123/003.html&title=asahi.com%uFF1A%u8F38%u5165%u725B%u8089%u306E%u5168%u91CF%u691C%u67FB%u300C%u7269%u7406%u7684%u306B%u4E0D%u53EF%u80FD%u300D%u3000%u8FB2%u6C34%u6B21%u5B98%u8868%u660E%A0-%A0%u66AE%u3089%u3057
I could get "mode" and "title" with param().
Also I could get "title" but the retrieved value was not correct.
Some characters
were disappeared.
The escaped string contains the character '&', so I thougt the parsing
URI function
has some problems but I don't have enough skill to read the XS codes, I can not
fix them.
Regards.
--
Naoya Ito <na...@hatena.ne.jp>