Pagination: Go to TOP of the table after button clicking

Pagination: Go to TOP of the table after button clicking

_PJ__PJ_ Posts: 7Questions: 0Answers: 0
edited November 2013 in General
Hello,

I have an issue to solve and hope someone can help me here.

When the user is clicking on the pagination buttons, the new pages load at the bottom of the table. I would like that after the user clicks, it will send automatically to the top of the table.

Any help will be much appreciated,
Thanks!

Replies

  • _PJ__PJ_ Posts: 7Questions: 0Answers: 0
    Help please!
  • rowelrowel Posts: 11Questions: 0Answers: 0
    I could use this feature too. I dynamically create new rows, and fill it via Ajax with a lot of information... this makes the table size really grow tall (even if I only display 10 records per page).

    Is there a callback available when any of the pagination links are clicked?
  • _PJ__PJ_ Posts: 7Questions: 0Answers: 0
    Hello,


    Is there a way how can I make the scroll go to the top (instead to the bottom, as is set up by default) after I click on a pagination button?

    Thanks
  • allanallan Posts: 63,498Questions: 1Answers: 10,471 Site admin
    Add an event listener to the pagination buttons, which when clicked will jump the scrolling to the top of the page.

    There are a number of threads already in the forum about this if you use the search function at the top of the page - for example:

    http://datatables.net/forums/discussion/158/x#Item_17
    http://datatables.net/forums/discussion/5426/go-to-top-page-on-page-navigation-button-click/p1

    Allan
This discussion has been closed.