Err..Nepo this is not related to Swings. Its regarding to jsf components ;)
Ah sorry, in that case no JCheckBoxes or JRadioButtons, but I'm sure there will be some kind of Radio buttons available in JSF.
...
There, found something. Look at this code:
- <f:use_faces>
-
<h:form formName="pform">
-
..........
-
<p><h:output_text value="Alignment:"/><br>
-
<h:selectone_radio id="align" valueRef="pbean.align"
-
layout="LINE_DIRECTION">
-
<f:validate_required/>
-
<h:selectitem itemValue="left" itemLabel="Left"/>
-
<h:selectitem itemValue="center" itemLabel="Center"/>
-
<h:selectitem itemValue="right" itemLabel="Right"/>
-
</h:selectone_radio>
-
<br><h:output_errors for="align"/>
-
..........
-
</h:form>
-
</f:use_faces>
It will generate this HTML code:
- <form method="post" action="/usingjsf/faces/edit.jsp">
-
..........
-
<p>Alignment:<br>
-
<table border="0">
-
<tr>
-
<td><input type="radio" checked
-
name="align" value="left"> Left</td>
-
<td><input type="radio"
-
name="align" value="center"> Center</td>
-
<td><input type="radio"
-
name="align" value="right"> Right</td>
-
</tr>
-
</table>
-
<br>
-
..........
-
</form>
There you go, radio buttons. They should work fine. :-)
Greetings,
Nepomuk <--- doesn't know much about JSF shamefully