For example I have this table:
id name action
1 john x
2 doe x
If I click x in the row when id is 1 it will be remove, how can I do that?
$('.btnDeleteitem').live('click', function() {
//
$.ajax({
url: 'wp-content/themes/twentyeleven-child/Delete.Item.php',
type: 'post',
data: { asin: $(this).attr('alt') },
success:function(){
//
}
});
Note: data from table is from database
Fiddle – http://jsfiddle.net/tariqulazam/s9cwt/
HTML
JQUERY
if you want to delete only the rows that has id=1 you can try this