jQuery delete table column

前端 未结 6 609
北荒
北荒 2020-12-17 00:40

I have a table and cannot change markup:

6条回答
  •  夕颜
    夕颜 (楼主)
    2020-12-17 01:18

    Remove the first column from each row.

    $('.mytable').find("tr td:nth-child(1)").each(function(){
        $(this).remove()
    });
    

提交回复
热议问题