How to get row id so i can link it to another page?
How to get row id so i can link it to another page?
danabud
Posts: 1Questions: 1Answers: 0
hi guys, im new to this datatables i have a problem when i want to get the row id
here my code:
$(document).ready(function() {
var table = $('#example').dataTable( {
"order": [[ 2, "desc" ]],
"aProcessing": true,
"aServerSide": true,
"ajax": "server-response.php",
"columnDefs": [
{
"targets": -1,
"data": null,
"defaultContent": '<a href="updatedata.php?aksi=edit&kodeRekap=">Edit</a>'
},
{
"targets": [ 9 ],
"visible": false,
"searchable": false
},
{
"targets": [ 12 ],
"visible": false
}
]
} );
my purpose is to make this
'<a href="updatedata.php?aksi=edit&kodeRekap=">Edit</a>'
to be like this
<a href="updatedata.php?aksi=edit&kodeRekap=<?php echo $line['id_rekap'] ?>">Edit</a>
so i can edit my row in another html page with the value record from row that i clicked
thanks for your help
This discussion has been closed.