How can I get the value of checkbox and radiobox
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Lauren_Gui
Posted On:   Thursday, August 21, 2003 01:35 AM

			

In struts 1.1.I know how to collect String by the tag to formbean.such as:
private String password = null;
...
public void setPassword(String password){
this.password = password;
}
public String getPassword(){
return password;
}
but how can I deal with checkbox and radio?
how to modify the formbean and jsp? and so on...
thanks:-)

Re: How can I get the value of checkbox and radiobox

Posted By:   Anjali_Hanuta  
Posted On:   Thursday, August 21, 2003 05:34 AM

Hi,

In the form bean you declare those variables as of type boolean.

For CheckBox


in tiles definition files you define like this




In Jsp page for check box u can write as


;







For Radio Button
















Hope this will help .
About | Sitemap | Contact