Ajax pagination - Having 1 page although iTotalDisplayRecords and iTotalRecords are set to 57
Ajax pagination - Having 1 page although iTotalDisplayRecords and iTotalRecords are set to 57
Hi,
Im trying to get datatable working with a server side response and have pagination working.
The problem is that although im setting iTotalRecords and iTotalDisplayRecords, it still shows only 1 page, or the total number of items (eg. if server returns 20, than shows 2 pages, but not all the pages based on the total records).
I have created this jsfiddle, where im manually setting the server response data in the fnServerData function.
http://jsfiddle.net/Na9aW/3/
Even if i define 10 records in aaData, it still shows only 1 page.
Because iTotalRecords is set to 57 i would have expected it to show the 6 pages and "1 to 2 of 57 entries".
Is there anything im missing?
Thanks for the help.
Im trying to get datatable working with a server side response and have pagination working.
The problem is that although im setting iTotalRecords and iTotalDisplayRecords, it still shows only 1 page, or the total number of items (eg. if server returns 20, than shows 2 pages, but not all the pages based on the total records).
I have created this jsfiddle, where im manually setting the server response data in the fnServerData function.
http://jsfiddle.net/Na9aW/3/
Even if i define 10 records in aaData, it still shows only 1 page.
Because iTotalRecords is set to 57 i would have expected it to show the 6 pages and "1 to 2 of 57 entries".
Is there anything im missing?
Thanks for the help.
This discussion has been closed.
Replies
> bServerSIde: true,
Should be:
> bServerSide: true,
:-)
Allan
Thanks!