View Single Post
Old October 17th, 2005, 10:16 AM
interrupt interrupt is offline
Friend of Wrox
Join Date: May 2004
Location: , , .
Posts: 212
Thanks: 0
Thanked 0 Times in 0 Posts

Hi Picco,

In my script I am doing that, but simply concatenating the id from the predefined string "r" and the number of the radio button which is (i) or (j) in my for loops. Like so:

document.getElementById("r" + i)

<input type="radio" id="r11" value=11 DISABLED>Radio 11

In the <input tag> its ID is "r11", so I make the id from specifying the string "r" and the value from the for loop (1 to 15, in this case 11).

Try the script, it does work. ;)