Hi all I am having a jsp page where I have entered radion button value ,like this:--
<td><input type="radio" name="billType" value="1"/> <font color =blue> Brief Bill</font></td>
<td><input type="radio" name="billType" value="2" /> <font color =blue>Detailed Bill</font></td>
<td><input type="radio" name="billType" value="3" /> <font color =blue>Itemized bill</font></td></tr>

Now I want to get this value in my class in an integer variable so that I can use it at other places also, how can I get this integer value out of it.

Member Avatar for stbuchok

Please try posting this in the JSP or Java forums. This is the JavaScript forum, which has absolutely nothing to do with Java or JSP.

@stbuchok please do not advise people to repost it as then they will face warning/infraction for multiposting. Instead of that hit "Flag Bad Post", write short message "move to JSP" and moderator/admin will take care of it

THREAD MOVED

Member Avatar for stbuchok

Will do from now on. Thanks.

use this link http://www.exampledepot.com/egs/javax.servlet.jsp/myform.jsp.html

and instead of String in the java bean use int and instead of initializing the values to "" use 0 or an int number

for the form (instead of true/false use values) and at top of header make sure you set the properties

<jsp:setProperty name="form" property="*" />
<p style="text-align:center;">Yes<input type="radio" name="check" value="true"<jsp:getProperty name="form" property="check" />/>No<input type="radio" checked="true" name="check" value="false" <jsp:getProperty name="form" property="check" />/></p>
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.