How to load data from an ajax request into DataTables

0

I'd like to know a way to load data from an ajax call into the datatables.

so that I can reload the table. I am loading by a method in ajax that passes to the table in the data object, but when I call the method again to reload the table I get the error:

  

DataTables warning: table id = images - Can not reinitialise DataTable. For more information about this error, please see link

    
asked by anonymous 16.04.2017 / 00:56

1 answer

1

After a long search I solved the problem. just add the following parameter at startup:

 destroy: true

source: StackOverflow EN

    
16.04.2017 / 01:10