velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <ch...@christopherschultz.net>
Subject [tools] StrutsLinkTool's setForward method has different behavior
Date Tue, 26 Jul 2011 21:27:01 GMT
All,

We use StrutsLinkTool pretty much everywhere and had been relying on the
previous behavior (tools 1.4) of StrutsLinkTool.setForward(String) which
takes a reference to a Struts-defined "forward" which is basically just
a URL.

In the past, we were able to define a URL in Struts like this:

<forward name="some-reference" path="/path/to/resource?foo=bar" />

Then, in the markup:

<a href="$link.setForward('some-reference')">link text</a>

It appears that somewhere in the modifications, the URL ha sbeen
sanitized and now "/path/to/resource?foo=bar" has been helpfully
replaced by "/path/to/resource%3Ffoo=bar".

Was this intentional? Is there a way to get the old behavior back?

Thanks,
-chris


Mime
View raw message