[
https://issues.apache.org/jira/browse/TOMAHAWK-1188?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12664449#action_12664449
]
Stefan Bley commented on TOMAHAWK-1188:
---------------------------------------
I'm facing the same problem.
<t:selectManyCheckbox id="chkFunc" value="#{userbean.functions}"
layoutWidth="3" layout="pageDirection"
style="left: 0px; top: 24px; position: absolute;" tabindex="6"
onclick="chkGroupChange(this);"
valueChangeListener="#{userbean.handleValueChangeFunc}">
<f:selectItems value="#{userbean.allFunctions}" />
</t:selectManyCheckbox>
renders to:
<table style="left: 0px; top: 24px; position: absolute;" id="form1:chkFunc">
<tr>
<td><label>View<input id="form1:chkFunc:0" type="checkbox"
name="form1:chkFunc" value="1" onclick="chkGroupChange(this);" tabindex="6"
/></label></td>
<td><label>Create<input id="form1:chkFunc:0" type="checkbox"
name="form1:chkFunc" value="2" onclick="chkGroupChange(this);" tabindex="6"
/></label></td>
<td><label>Send<input id="form1:chkFunc:0" type="checkbox"
name="form1:chkFunc" value="3" onclick="chkGroupChange(this);" tabindex="6"
/></label></td>
</tr>
<tr>
<td><label>Delete<input id="form1:chkFunc:0" type="checkbox"
name="form1:chkFunc" value="4" onclick="chkGroupChange(this);" tabindex="6"
/></label></td>
...
</tr>
</table>
I use Tomahawk12 1.1.8 and JSF Mojarra 1.2_07
> many HtmlCheckbox rendered with the same id with HtmlSelectManyChecbox spread
> layout
> ------------------------------------------------------------------------------------
>
> Key: TOMAHAWK-1188
> URL: https://issues.apache.org/jira/browse/TOMAHAWK-1188
> Project: MyFaces Tomahawk
> Issue Type: Bug
> Affects Versions: 1.1.6
> Environment: Tomahawk + JSF-RI 1.2.06 + Facelets
> Reporter: Marcin Kobylarz
> Assignee: Leonardo Uribe
> Fix For: 1.1.7
>
>
> This piece of code:
> <t:selectManyCheckbox id="xxx" layout="spread"
> value="#{checkboxTest.selectedItems}">
> <t:selectItems value="#{checkboxTest.items}" var="item"
> itemValue="#{item}" itemLabel="#{item}" />
> </t:selectManyCheckbox>
> <t:checkbox id="item1" for="xxx" index="0"></t:checkbox>
> <t:checkbox id="item2" for="xxx" index="1"></t:checkbox>
> causes all the checkboxes to be rendered to html with the same id. This
> violates html object id uniqueness.
> Solution:
> ---
> tomahawk_1.1.6/org/apache/myfaces/renderkit/html/ext/HtmlCheckboxRenderer.java
> 2007-03-23 10:05:42.000000000 +0100
> +++
> tomahawk_patched/org/apache/myfaces/renderkit/html/ext/HtmlCheckboxRenderer.java
> 2008-01-31 16:21:28.000000000 +0100
> @@ -406,7 +406,7 @@
> itemStrValue,
> selectItem.getLabel(),
> isDisabled(facesContext,uiSelectMany),
> - lookupSet.contains(itemStrValue), true);
> + lookupSet.contains(itemStrValue), false);
> }
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.