Marcos, use this ::
<s:iterator id="foto" value="fotosGaleria" status="stat"> <s:checkbox name="sel" theme="simple" fieldValue="%{codFotoGaleria}"> </s:checkbox> </s:iterator> inte+ Herrera Marcos Mendonça wrote: > > Hello > > I'm trying to use checkboxes for a service/product selection. But > following the documentation I wasn't able to set the value of each > option. > > My code: > > <s:iterator value="%{services.iterator}"> > <tr> > <td> > <s:checkbox label="%{name}" name="name" value="id"/></td> > </tr> > </s:iterator> > > Resulting in > > <input type="checkbox" name="id_produto" value="true" > checked="checked" id="selecaoProduto_id_produto"/> > <input type="hidden" name="__checkbox_id_produto" value="true" /> > <label for="selecaoProduto_id_produto" > class="checkboxLabel">Service1</label> > </td> > > Shouldn't the value attribute be set to whatever the id of my service is > set to? > > Why is value="true" instead of my service id? > > How do I recover this in my action to find what wich services where > selected by the user? > > Thanks. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/Using-checkboxes-tf4374405.html#a12476316 Sent from the Struts - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]