in the Action, you need a list; List<String> checklist;//getter & setter then, you can get the fieldValue="Y" in the struts tag, from field "checklist" in the Action. and the value is the same value in html tag value="Y".
On Wed, Oct 22, 2008 at 3:50 PM, Harden ZHU <[EMAIL PROTECTED]> wrote: > I have a checkbox in jsp: > > <s:checkbox name="user.contactConfidential" fieldValue="Y" />, > after html rendering it is shown as <input type="checkbox" > name="user.contactConfidential" value="Y" > id="user.contactConfidential"/>, that is good. > > But once a user selects the checkbox and submits the form, > user.contactConfidential is set to true. However, on the database side > the value should be stored as 'Y' or 'N'. Is there anyway that I can > get user.contactConfidential="Y" when submits form instead of > true/false? > > Thanks > > Harden > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- BestRegards, Mead http://yayisoft.com George Burns - "When I was a boy the Dead Sea was only sick."