I want to delete all the rows of a table where the text of the first row matches a specific text. Take into account the text has to be an exact match. So if I look for those rows that contain the text "34" it should delete only those with the text "34" but not those with text "3434" for example. I was using "contains" before but it was deleting all rows containing "34" somwhere within the text, not only the exact matches.
I tried this but it isn't working since it doesn't delete anything.
$("#induction-table td").filter(function() {
return $(this).text() == '"'+exp+'"';
}).closest("tr").remove();
So the text I want to match is in the variable exp. Also is there a way to check for the text only on one specific td of the tr and not on all? That would be pretty useful too.