Base solution for your next web application
Starts in:
01 DAYS
01 HRS
01 MIN
01 SEC
Open Closed

DataTables from HTML #6831


User avatar
0
robrechtbelien created

Hi,

I have an HTML table and I want to use datatables to show it in a better way. When I just use the default: $('#example').DataTable(); All rows disappear and instead it shows one row with the "Loading..." text.

Any help would be greatly appreciated.


4 Answer(s)
  • User Avatar
    0
    maliming created
    Support Team

    This problem seems to have nothing to do with zero. Can you share some code?

    datatables document: https://datatables.net/examples/data_sources/dom

  • User Avatar
    0
    robrechtbelien created

    The same code is working in another project. It seems that either metronic or abp is overriding the default initializing for datatables.

  • User Avatar
    0
    robrechtbelien created

    I found the solution; I needed to override the "ajax" option when initialising the datatable and set it to null.

  • User Avatar
    0
    robrechtbelien created

    I found the solution; I needed to override the "ajax" option when initialising the datatable and set it to null.