Remove table row using jQuery

前端 未结 6 1646
别跟我提以往
别跟我提以往 2021-02-19 03:57

The following is my code

Script

$(document).ready(function(){
    $(\'#click\').click(function(){
        $(\'#table\').append(\'&a         


        
6条回答
  •  陌清茗
    陌清茗 (楼主)
    2021-02-19 04:44

    You can remove the last tr from the table using the table class on button click.

    $('#remove').on("click", function(){
        $('.tbl tr:last').remove();
    });
    
    
     
     

提交回复
热议问题