arkadaşlar aşaıdaki kod ile tablodaki satırları ekle deyince tablo altında seçili olan satırların id lerini yazıyor ama ben bu idleri <li>içerisinde değilde hepsini textarea da göstemek istiyorum nasıl yapabilirim acaba şimdiden teşekkürler
<button id="add_cart">Ekle</button>
<ul id="output"></ul>
<script type="text/javascript">
var checkedRows = [];
$('#eventsTable').on('check.bs.table', function (e, row) {
checkedRows.push({id: row.id, name: row.name, forks: row.forks});
console.log(checkedRows);
});
$('#eventsTable').on('uncheck.bs.table', function (e, row) {
$.each(checkedRows, function(index, value) {
if (value.id === row.id) {
checkedRows.splice(index,1);
}
});
console.log(checkedRows);
});
$("#add_cart").click(function() {
$("#output").empty();
$.each(checkedRows, function(index, value) {
$('#output').append($('<li></li>').text(value.id + " | " + value.name + "" ));
});
});
</script>