On click input value at server side

On click input value at server side

ashwinicsashwinics Posts: 0Questions: 1Answers: 0
edited February 2018 in Free community support

Hello, On click button, I am not getting my input value on the server side. Please help me.

var table = $('#users-table').DataTable({
processing: true,
serverSide: true,
lengthChange: false,
searching: false,
pageLength: 50,
responsive: {
details: false
},
columnDefs: [{
'targets': 0,
'searchable': false,
'orderable': false,
'className': 'dt-body-center',
'render': function (data, type, full, meta){
return '<input type="checkbox" name="id[]" class="dt-checkboxes" value="' + $('<div/>').text(data).html() + '">';
}
} ,
{ orderable: false,
targets: [6]
}
],
order: [
[ 0, "desc" ]
],
"ajax": {
headers: {
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
},
"url": "{!! route('getArtistList') !!}",
"type": "POST",
},
columns: [
{ data: 'id', name: 'S.NO' },
{ data: 'id', name: 'id' },
{ data: 'name', name: 'name' },
{ data: 'other_name', name: 'other_name' },
{ data: 'seokey', name: 'seokey' },
{ data: 'status', name: 'status' },
{ data: 'action', name: 'action' }
]
});

$('#submitButton').click(function(e){
var i =jQuery(this).attr('id');
table.search( i).draw();
});

This discussion has been closed.