> I'm trying to implement mapped properties for buttons on a form. 
> Given the following code:
> 
> private Map<String, String> removeButtons = new HashMap<String, 
String>();
> public Map<String, String> getRemoveButtons() {
>     log.debug("Call to getRemoveButtons()");
>     return removeButtons;
> }
> 
> and the following HTML:
> 
> <input type="submit" value="Remove" name="removeButtons['<string>']"
> id="removebuttons['<string>']"/>
> 
> the getRemoveButtons function is never called if the string has 
> whitespace in it. Is this by design or a bug? Is there a workaround?
> 


A way to bypass this restriction is to use ParameterNameAware:


https://struts.apache.org/release/2.0.x/docs/parameters-interceptor.html
https://struts.apache.org/release/2.0.x/struts2-core/apidocs/com/opensymphony/xwork2/interceptor/ParameterNameAware.html



regards,
Christoph


This Email was scanned by Sophos Anti Virus

Reply via email to