I want to delete a row which is checked but my program is deleting all the rows with input type: checkbox. iam using javscript in jsp
Code:
function deleteSelectedRows() {
$('#dataTable tr').each(function() {
$(this).find('input[type="checkbox"]:checked').each(function() {
$('#delDependNames').attr("value", $('#delDependNames').attr('value') + "," + $(this).val());
$(this).closest('tr').remove();
displayNamesC();
});
});
}
Comment