set textbox value to selected radio button one
I have three radio buttons and one textbox. If user select one of those radio buttons and type something in the textbox which is the value of the textbox, I want that value to be the value of the radio button that is selected, now the user may enter the value into the text box and then select the radio button or first select a radio button then enter something to the textbox, anyway the value of radio button should be equal to textbox value that user enter!
additional explanation :
(I have three radio buttons and one text box in a form which is for shipment tracking, now what I need is when I type something in that textbox (which is the value) and select one of those three radio buttons then clicking on go (submit) textbox value and selected radio button value will pass through URL (get method) on the result page I see two different value, one for my textbox and one for the selected radio button ,now I want that selected radio button value be as exact as the textbox one so the selected radio button value should follow the textbox value and both be equal so for example when I type some number like 870 in the textbox and select one of those three radio buttons an submit the form the result page URL have to show the radio button value 870 as the textbox is.)
The important point is changing value is just an option I mean it's not necessary that radio button values being changed it could be empty of any value and then fill by textbox value. I just want the selected radio button value ( One of those three radio buttons which user selected ) to be the exact same as user typed in textbox.
This could be done with js or something !
My Form code :
<form id="Shipment" name="Shipment" method="get" action="tope_results.asp" class="zero" onSubmit="popupform(this, 'join')">
<input type="radio" name="SrchQuery" id="n4" value="CNTR" />
<input type="radio" name="SrchQuery" id="n2" value="BLNo" />
<input type="radio" name="SrchQuery" id="n3" value="Fln"/>
<input name="button" type="submit" class="SHN" id="button" value="GO"/>
thanks so much.