mardi 4 août 2015

Access from change event to other input html jquery autocreate

My problem is:

I have a page with a table is auto generated with ajax-jquery

My table is 3 1: name 2-3: checkbox for parameters

I set event on all input:checkbox ("change") event.

The problem appears when i try to get check state of checkbox different than i click.

code:

$(document).ready(function() {

   $("#permessiAttributiDiv").on("change", "input:checkbox", function() {
        var IDPermesso = $(this).attr("id").substring(1);
        var selezionatoSpuntato = (this.checked);
        var altro = $(this).parent().find("input:checkbox").checked;
        var scheda = $("#selectTipo").val();
    });
)};

I also try to get check state by id but i always doesn't work......

I see if the checkbox is write in html static code all works ok but if i generate it with jquery i can't access to input with any selector.....

Can anyone help me?

Thanks




Aucun commentaire:

Enregistrer un commentaire