Editing Pagination button size
Editing Pagination button size
D19cannon
Posts: 15Questions: 3Answers: 0
Hi guy! I have been searching for an option that defines how many buttons you have in the pagination.
My current situation looks as follow:
And I wish to remove page 4 and 5 for instance.
Tabulator plugin had a solution that was:
$("#example-table").tabulator({
paginationButtonCount:7,
});
Is there similar solution for datatables?
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
Yes, but its currently not documented:
Is the source.
Allan
Hi Allan! Thanks for the quick response. I see your solution, however, I do not understand how to apply it? Is there a setting option or anything, something like this: ?
You would set that parameter before initialising the DataTable as its a static parameter:
Allan
I tried to do it the way you suggested. Unfortunately, without luck so i tried a few different ways. Calling before the table is called, when the DOM is initialised, but that didn't work either.
Any other suggestions?
Daniel
Update: I can see something is happening, because when change 'pager' into 'page' it won't load my page any more. So, is there a function which is maybe similar to that one?
Ooops - its
numbers_length
! http://live.datatables.net/dotoyico/1/editAllan
Great it worked! Thank you very much Allan, it's appreciated