[
http://issues.apache.org/click/browse/CLK-491?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=11698#action_11698
]
Naoki Takezoe commented on CLK-491:
-----------------------------------
Thanks for Malcolm and Bob,
> I understand the need for a list of hidden values, but what about encoding
> these in the hidden field value.
I wish to convert values of controls to hidden field.
Single parameter controls can be converted to HiddenField.
But controls which have multi values such as Select, CheckList or PickList can
not be converted.
It need encoding values to a single string as Malcolm says.
If I have a HiddenList, I would be able to convert these controls naturally.
And Select(or CheckList, PickList) would be able to receive sent values by
HiddenList directly.
> I agree with Malcolm, extras is probably a better fit for now.
>
> We should also add an example under "Controls" to show its usage.
Anyway, I agree with Malcolm and Bob. I would add HiddenList to extras.
> HiddenList control
> ------------------
>
> Key: CLK-491
> URL: http://issues.apache.org/click/browse/CLK-491
> Project: Click
> Issue Type: New Feature
> Components: extras
> Affects Versions: 2.0.1
> Reporter: Naoki Takezoe
> Assignee: Naoki Takezoe
> Priority: Minor
>
> Form control does not allow to add fields as same name.
> So we can't send multi parameters using hidden field.
> I think new HiddenList control can solve this issue.
> For example:
> ----
> HiddenList hiddenList = new HiddenList("hiddenList");
> hiddenList.addValue("1");
> hiddenList.addValue("2");
> hiddenList.addValue("3");
> form.add(hiddenList);
> ----
> Generated HTML:
> ----
> <input type="hidden" name="hiddenList" value="1"/>
> <input type="hidden" name="hiddenList" value="2"/>
> <input type="hidden" name="hiddenList" value="3"/>
> ----
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.