Dinamic checkbox

Dinamic checkbox

Hi all,

my page create dinamically... For example...

I click "this" I add 5 checkbox (a,b,c,d,e) to page. If I click "that" I add others 3 (f,g,h) checkbox to page.

Then i checked first one checkbox i get correct checked item... but second, third... I get undefined because my page create dinamic html.

  1. //add checkbox to page:
  2. html += "<input type='radio' name='idTipoScommessa' id='idTipoScommessa' value='...'  />";

  3. //get checked item
  4. var idTipoScommessa = $("#idTipoScommessa:checked").val();
Help me and sorry for my english

Thanks