View Full Version : To Retrieve dynamic radio button values using jsp & javascript

12-13-2007, 09:34 AM
Hi All,

How can i retrive the dynamically created radio button values. I am using JSP and JAVA beans to retrive the values from the form. I dont have any probs to retrieve combo box values, text box values only problem showing with radio button values. If any data which is entered wrong in the form all the fields should prefills with the old value.Except radio button values all others fields such as combo box, text box values are prefilled.

I have given the code for radios.

document.write('<td class="Amenu_rouge" >Are you currently?&nbsp;&nbsp;&nbsp;&nbsp;');
document.write('<input type="radio" name="distradio" OnClick="sampleReq.fcidis.value=\'Y\'"/>Yes &nbsp;&nbsp;');
document.write('<input type="radio" name="distradio" OnClick="sampleReq.fcidis.value=\'N\'"/>No');
document.write('<input type="hidden" name="fcidis" value="">')

<form method="POST" action="Update.jsp" name="sampleReq" >

<td class="Txt_gris">
<input type="radio" name="requester" OnClick="sampleReq.requester1.value='supplier'"/> supplier
<td class="Txt_gris">
<input type="radio" name="requester" OnClick="sampleReq.requester1.value='customer'"/>customer
<td class="Txt_gris">
<input type="radio" name="requester" OnClick="sampleReq.requester1.value='distributor'"/> distributor
<td class="Txt_gris">
<input type="radio" name="requester" OnClick="sampleReq.requester1.value='employee'"/> employee
<td class="Txt_gris">
<input type="radio" name="requester" OnClick="sampleReq.requester1.value='New partner'"/>New partner
<input type="hidden" name="requester1" value=""/>

Advanced Thanks for help


EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum