How to reload the datatable(jquery) data?

后端 未结 10 2490
萌比男神i
萌比男神i 2020-12-05 05:39

How to reload the selected tab? Actually I have problem with reloading part. When I add my data I\'ll successfully saved in datatable but in id field in database it shows pr

10条回答
  •  温柔的废话
    2020-12-05 06:01

    Simpler solution:

    var dt = $('#table_scroll').dataTable();
    
    $.getJSON(url, null, function (json) {
        dt.fnClearTable();
        dt.fnAddData(json.aaData);
        dt.fnDraw();
    });
    

提交回复
热议问题