cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Fuad Efendi" <>
Subject RE: URI decoding problem
Date Tue, 06 Feb 2007 03:50:06 GMT
Thanks Alex,

Latest news:

1. I don't have any problem when I access Tomcat (Cocoon) directly.
2. I have problems only when I access Cocoon via Apache HTTPD front-end.

By somehow, HTTPD converts user's request /CD%20%2B%20DVD/ into
/CD%20+%20DVD/. Of cource, Tomcat (and Cocoon) misunderstands it as
/CD+++DVD/, or /CD   DVD/

It's most probably bug in AJP/1.3, not related to Cocoon...

As a workaround, I use java.lang.String(...).replaceAll("+","%2B") before
forwarding request to another pipeline...

-----Original Message-----
From: Alexander Klimetschek [] 
Sent: Monday, February 05, 2007 4:08 AM
Subject: Re: URI decoding problem

Fuad Efendi schrieb:
> API Docs are probably with typo:
>  * &lt;map:generate
> public final class URLDecodeModule extends AbstractInputModule
>                                    implements ThreadSafe {
> {url-decode:...}? instead of url-encode?

Depends on what you are doing. The example above
(http://remote/page?param1={url-encode:{request-param:param1}}) makes a http
call from inside Cocoon and uses a parameter of the original request 
"{request-param:param1}". This request parameter is already decoded,
depending on the standard encoding of the servlet container and Cocoon's
encoding settings:


(Default value is actually ISO-8859-1, for more information see [1])

For the new request those have to be re-encoded again, that's why there is
"{url-encode:....}" in the example.

If you don't get correctly decoded request parameters, try to set those
encoding properties, the mentioned wiki page should help).



Alexander Klimetschek

View raw message