Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想通过html div格式中的javascript添加带有删除按钮的行。
任何帮助表示赞赏!
谢谢
$('<div>').append( $('<button>').text('remove').click(function(){$(this).parent().remove()}) ).appendTo($(document.body))