With sAjaxSource, how to build ?

With sAjaxSource, how to build ?

liblib Posts: 9Questions: 1Answers: 0
edited April 2014 in DataTables 1.9
I've built the table as:
[code]



id
periodo



Row 1 Data 1
Row 1 Data 2


[/code]
Get the results from the database and they are displayed in the table. This is working, for example, for 23 results.

But, in http://www.datatables.net/usage/ you show that should be built like:
[code]


Row 1 Data 1
Row 1 Data 2
etc


Row 2 Data 1
Row 2 Data 2
etc


[/code]
Two rows... What does this mean exactly? What I'm doing is wrong? Do I have to code 100 ... rows? 100 = maximum number of rows available to be shown?

I'm also considering using one of the plugins, the Scroller. So, what exactly should I write inside the ?

Replies

  • allanallan Posts: 61,451Questions: 1Answers: 10,055 Site admin
    The example you link to is the simplest possible use case - DOM sourced data. If you have Ajax sourced data then you don't need to put anything in the tbody, DataTables will do it automatically for you.

    The new manual for DataTables 1.10 might help: http://next.datatables.net/manual/data#Data-sources

    Allan
  • liblib Posts: 9Questions: 1Answers: 0
    Thank you very much! Have a nice day.
This discussion has been closed.