How to disable pagination for small tables
How to disable pagination for small tables
kj_rk
Posts: 1Questions: 1Answers: 0
I see examples of disabling pagination and ordering on the examples page. Can I add a logic to check the number of rows in the table and disable these features for small tables (where numOfRows <= 5) or any number of our choice.
Thanks in advance
This discussion has been closed.
Answers
You will need to check for the number of rows before initializing Datatables. You can then use a boolean variable in the init code to enable/disable paging and ordering.
Kevin