0
このコードを見ましたが、同じボタンをクリックしてdivコンテンツを非表示にする方法を知りたいと思います。 .toggle()を配置しようとしましたが、どこに置くべきかわかりません。私はまだjavascriptとjqueryを学んでおり、私は多くの問題を練習しています。htmlテーブル行のdivコンテンツの切り替え
JS:
$(document).delegate('input[type="button"]','click',function(){
$('[colspan="5"]').parent('tr').remove();
$(this).parents('tr').after('<tr/>').next().append('<td colspan="5"/>').children('td').append('<div/>').children().css('background','#f0f0f0').html($('#content').html());
});