I can't manipulate the cells of my table with JQuery
I have a jsp where I call other jsp with a JQuery/Post which prints a table dynamically
$(document).ready(function(){     
    var usuario =  $("#Id").text();
    var s = "13";
    $.post("../Querys/select_subcategoria.jsp",{s:s,usuario:usuario})
        .done(function(data) {
            $("#tab-index-div").append(data);
        });
});
it appends into a div.
then I have this code that helps to do a click in the hole tr and then it triggers a link
$('#tab-search tr').click(function() {
    var href = $(this).find("a").attr("href");
    if(href) {
        window.location = href;
    }
});
It works if I print the table in the same JSP, but doesn't work if I print it in the other JSP, I tried to append the data into a table, and just append the <tr>, but doesn't work too.
I think JQuery does not recognize the ID of the table
If anyone has any ideas it would be a great help.
 
     
     
    