Getting paging data in Ajax

Getting paging data in Ajax

jstuardojstuardo Posts: 104Questions: 41Answers: 0

Hello,

I am thinking about using this plugin to have a grid in my page, however, I was seeing examples regarding AJAX data loading.

I saw that always all data is actually retrieved, even if only the first 10 are displayed in the grid.

Is there a way to make it more efficient? other grid components allow to return an object that contains total records number, current page, current record and finally, the requested records.

Is this possible using this component or was this component planned to be used with small sets of data only?

Regards
Jaime

This question has an accepted answers - jump to answer

Answers

  • colincolin Posts: 15,240Questions: 1Answers: 2,599
    Answer ✓

    Hi @jstuardo ,

    Yep, DataTables supports that - it can be used with any number of rows. If you enable serverSide, then the server only returns the information that will be displayed on the screen, so 10 in your example. There's some examples here.

    Cheers,

    Colin

  • jstuardojstuardo Posts: 104Questions: 41Answers: 0

    Thanks! I started using it using server side processing.

This discussion has been closed.