Click here to Skip to main content
16,006,065 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi I m working in asp.net mvc razor


I have few radio button ,
HTML
<input type="radio" name="1strm" value="shree=1&shru=cd" />Firstone
<input type="radio" name="1strm" value="shree=4&shru=ss" />Firsttwo
<input type="radio" name="1strm" value="shree=2e&shru=wse" />Firstthree
<input type="radio" name="1strm" value="shree=re&shru=474" />Firstfour
<input type="radio" name="1strm" value="shree=121&shru=58" />Firstfive

and

HTML
<input type="radio" name="1strm" value="shree=1&shru=cafad" />Secondone
<input type="radio" name="1strm" value="shree=cc&shru=sssa2" />Secondtwo
<input type="radio" name="1strm" value="shree=wee&shru=w42se" />Secondthree
<input type="radio" name="1strm" value="shree=rwse&shru=4d74" />Secondfour
<input type="radio" name="1strm" value="shree=1211&shru=5sw8" />Secondfive


what i want is to add both input radio button value in a anchor tag href ..so i can pass value

i want to href="" to other page , with value from both input radio , but not as parameters with href


how to do this

currently, i tried to add in href as parameter from jquery radio onclick , but that shows value of radio button in url , which i dont want to show

How can i pass value from radio clicked, to other page on a tag href
Posted
Updated 11-Jun-14 20:28pm
v2

1 solution

If you want to pass that through href, then that would definitely show in URL. But what you can do is that, you can Encode the value while sending it and Decode while receiving it.

For Encoding Decoding, refer - Base64 encoding and decoding in client-side Javascript[^].
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900