JQuery:
$('#imgDelete').live('click', function() {
$(this).parent('td').remove();
});
All <td> are generate pro-grammatically and bind.imgDelete is also bind inside for each <td>.But above code shouldn’t able to remove parent. Dynamically generate columns are unable to delete or i m missing something. Thanks.
Try with:
Look for the difference between
.parent()and.parents()(I’m supposing that
imgDeleteisn’t a direct child oftd) (Also, you should use class instead of id, as has been said)