How do I use an activation key to change pages?
How do I use an activation key to change pages?
I came across this post:
https://datatables.net/reference/option/buttons.buttons.key
And I found it really useful as an implementation of keyboard shortcuts for doing the likes of copying, downloading as excel, printing, toggling column visibility etc
My question is, what would be the best way to achieve keyboard page changing via the right left keys, or ctrl/shift/alt + right left keys?
Searching the forums I came across this as well:
https://datatables.net/forums/discussion/comment/37022/#Comment_37022
Does this legacy based code work just as well in the newer version of DT?
I also came across this:
https://datatables.net/extensions/keytable/examples/initialisation/simple.html
But it seems the page change on keypress only happens at the end or beginning of a celled table, and is basically tabbing through all the cells, which isn't the exact functionality I'm looking for.
This question has an accepted answers - jump to answer
Answers
https://datatables.net/plug-ins/pagination/input
This pagination plug-in enables left/right arrow keys.
I tried using that plugin, although there now appears an input box where I can type in a page number to go to, I am still unable to change pages with the arrow keys.
Also, I find that the buttons styling has been stripped raw.
https://jsfiddle.net/p4fgegdy/
The arrow keys are working in your jsfiddle. The page number input box must have focus.