your way is definitely more elegant and will work regardless of what they decided to make the id's.
On Dec 28, 10:48 am, MorningZ <morni...@gmail.com> wrote: > If it was me, I'm not sure i would hide the row from the user, because > as an example, what happens if I accidentally select the "9" choice? > by hiding the row from the user's view, you do not give them the > ability to fix that mistake... > > none the less, you can do what you seek without worrying about > breaking up and parsing out the id's of the controls/rows, jQuery's > "parent()" selector makes this easy: > > case in point:http://jsbin.com/uberi/edit > > also note the usage of event delegation, which allows one single DOM > object, the <table>, to have the event latched onto it, which may be a > big resource saver if you've got a ton of these rows/radio-buttons....