[
https://issues.apache.org/jira/browse/MYFACES-4072?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15610536#comment-15610536
]
Leonardo Uribe commented on MYFACES-4072:
-----------------------------------------
For now I can confirm MyFaces Renders this:
{code:xml}
<form id="form" name="form" method="post"
action="/jsf22-html5/customLayoutRadio.jsf"
enctype="application/x-www-form-urlencoded">
<ul>
<li><input id="form:items:0:item" name="form:selectedItem"
checked="" type="radio" value="one" /><label for="form:items:0:item">one</label>
</li>
<li><input id="form:items:1:item" name="form:selectedItem"
checked="checked" type="radio" value="two" /><label
for="form:items:1:item">two</label>
</li>
<li><input id="form:items:2:item" name="form:selectedItem"
checked="" type="radio" value="three" /><label
for="form:items:2:item">three</label>
</li>
</ul>
<input id="form:submit" name="form:submit" type="submit" value="Submit"
/>
<input type="hidden" name="form_SUBMIT" value="1" />
<input type="hidden" name="javax.faces.ViewState"
id="j_id__v_0:javax.faces.ViewState:1"
value="b9qVRgNs/wKFdsAP3oIgPoZFX8heAQh6R3+7sgi+6L/dhVtO" autocomplete="off" />
</form>
{code}
And mojarra render this:
{code:xml}
<form id="form" name="form" method="post"
action="/jsf22-html5/customLayoutRadio.jsf"
enctype="application/x-www-form-urlencoded">
<input type="hidden" name="form" value="form" />
<ul>
<li><input id="form:items:0:item" name="form:selectedItem"
type="radio" value="one" /><label for="form:items:0:item">one</label>
</li>
<li><input id="form:items:1:item" name="form:selectedItem"
checked="checked" type="radio" value="two" /><label
for="form:items:1:item">two</label>
</li>
<li><input id="form:items:2:item" name="form:selectedItem"
type="radio" value="three" /><label for="form:items:2:item">three</label>
</li>
</ul>
<input id="form:submit" type="submit" name="form:submit" value="Submit"
/>
<input type="hidden" name="javax.faces.ViewState"
id="j_id1:javax.faces.ViewState:0"
value="5500419563705987603:392175610494501202" autocomplete="off" />
</form>
{code}
So, MyFaces does not make differences between null as empty string, but Mojarra
does. I need to read the spec to see if this behavior was described or not first
> passthrough checked always set
> ------------------------------
>
> Key: MYFACES-4072
> URL: https://issues.apache.org/jira/browse/MYFACES-4072
> Project: MyFaces Core
> Issue Type: Bug
> Affects Versions: 2.2.3
> Environment: TomEE 7.0.1
> Reporter: Matthew Broadhead
>
> following the tutorial outlined in this BalusC article
> http://balusc.omnifaces.org/2015/10/custom-layout-with-hselectoneradio-in.html
> it seems that when a:checked
> (xmlns:a="http://xmlns.jcp.org/jsf/passthrough") is set to null it still
> renders as checked.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)