This week's book giveaway is in the OCPJP forum.
We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line!
See this thread for details.
The moose likes HTML, CSS and JavaScript and the fly likes jQuery Datatable pagination help Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "jQuery Datatable pagination help" Watch "jQuery Datatable pagination help" New topic
Author

jQuery Datatable pagination help

Joe Stela
Greenhorn

Joined: Mar 22, 2012
Posts: 16
Hello,

I am using Jquery datatable.



I am using default pagination and displaying 25 records at a time. when user clicks on next button user can see next 25 records. I want to execute some code when user clicks on next/prev buttons. For that I want to know whether user has clicked next or prev button.

Can anybody tell me how will I know which button user has clicked?

If I use "fnDrawCallback":functionName , I just get the information that user is navigating to next/prev page. Can I also get prev/next button information in this function?
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61451
    
  67

The documentation of the plugin should have the details of the information that is published with the events.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Joe Stela
Greenhorn

Joined: Mar 22, 2012
Posts: 16
My problem got solved...

We can use "fnInfoCallback" instead of fnDrawCallback.

fnInfoCallback gives all the information related to records on page.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61451
    
  67

Thanks for posting back with your findings.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: jQuery Datatable pagination help