NoParameters blocks action tag params instead of request params
---------------------------------------------------------------
Key: WW-2795
URL: https://issues.apache.org/struts/browse/WW-2795
Project: Struts 2
Issue Type: Bug
Components: Core Interceptors
Affects Versions: 2.1.2
Reporter: Raphael Kirchner
Priority: Minor
According to JavaDoc, org.apache.struts2.interceptor.NoParameters should be
"should be implemented by actions that do not want any parameters set on them
automatically. This may be useful if one is using the action tag and want to
supply the parameters to the action manually using the param tag."
Actually something like the opposite happens: The action tag param gets blocked
and the request param is used instead
Example:
<@s.action name="Foo" executeResult="true"
ignoreContextParams="true" >
<@s.param name="input">embedded</@>
</@s.action>
With Foo implementing NoParams,
1) Foo.action results in Foo.input == NULL
2) Foo.action?input=test results in Foo.input == "test"
Where it should be "embedded" in both cases.
<@s.action name="Foo" executeResult="true"
ignoreContextParams="true" >
</@s.action>
With Foo implementing NoParams,
1) Foo.action results in Foo.input == NULL
2) Foo.action?input?test results in Foo.input == "test"
Where it should be NULL in both cases,
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.