[ 
https://issues.apache.org/struts/browse/WW-2617?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Musachy Barroso resolved WW-2617.
---------------------------------

    Resolution: Duplicate

Fixed by James Holmes on rv660539, although the comments refers to WW-2566

> Disabled attribute on checkbox should also disable the automatically created 
> hidden formfield
> ---------------------------------------------------------------------------------------------
>
>                 Key: WW-2617
>                 URL: https://issues.apache.org/struts/browse/WW-2617
>             Project: Struts 2
>          Issue Type: Bug
>    Affects Versions: 2.0.11.1
>            Reporter: Jelmer Kuperus
>
> Disabling a html form element  will cause its value not to be posted. 
> when you disable a checkbox using  <s:checkbox name="somename" 
> disable="true"/>
> the value is still submitted because the hidden formfield that is created is 
> not disabled.
> The quick fix would be to change
> <input type="hidden" name="__checkbox_${parameters.name?html}" 
> value="${parameters.fieldValue?html}" />
> in checkbox.ftl to:
> <input type="hidden" name="__checkbox_${parameters.name?html}" 
> value="${parameters.fieldValue?html}" 
> <#if parameters.disabled?default(false)>
>  disabled="disabled"<#rt/>
> </#if>
> />

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to