On my local (Homestead) environment, datatables works perfectly.
However, after deployment I have noticed that ordering, sorting and pagination does not work. All rows are displayed at once.
This is strange as the code is identical! As far as I can tell.
I have notice that the "draw" doesn't update on the Live version, whereas it does on the Local version, e.g.:
Working: https://www.dropbox.com/s/bgynunxoewpa8d3/Screenshot%202016-07-30%2013.25.20.png?dl=0
Non working: https://www.dropbox.com/s/1e0dh1u2onr7v6c/Screenshot%202016-07-30%2013.25.28.png?dl=0
And the limit on the query is not applied.
Code snippet of JS:
$(function() {
$('#jobs-table').DataTable({
processing: true,
serverSide: true,
ajax: '{!! route('jobs_datatable') !!}',
columns: [
{data: 'ref', name: 'jobs.ref'},
{data: 'status', name: 'jobs.status'},
{data: 'name', name: 'jobs.name'},
{data: 'customer.company_name', name: 'customer.company_name'},
{data: 'order_date', name: 'jobs.order_date', searchable: false},
{data: 'action', name: 'action', orderable: false, searchable: false, className: "text-right"}
],
order: [[ 4, "desc" ]]
});
});
Example of incorrect pagination ("showing 1-10 of 17" but actually showing all 17)

@tomhoad, based on your not working screenshot, it appears that the input parameters are not being sent/received by the server input: []. Not sure how it happens but that should give you some direction to debug.
Thanks @yajra - I bet my nginx.conf is stripping the query strings for whatever reason on the Live server! I'll report back once I amend.
Adding
try_files $uri /index.php?$query_string;
to my nginx.conf solved this
where should i put try_files $uri /index.php?$query_string; ?
@yajra Thanks
@tomhoad tomhoad Thanks, that work for me to
Most helpful comment
Adding
to my nginx.conf solved this