Datatable is not changing the data into table even network calls are showing perfct activity from se
Datatable is not changing the data into table even network calls are showing perfct activity from se

First time data appears but when i do any sorting now data is populating into table. I have checked the network calls. Server is responding fine something is wrong with datatable. Also "processing...." div is not hiding it seems UI does not know that response is back from server.
This discussion has been closed.
Answers
I responded to your question in this thread. Please don't duplicate your questions. Here is my response, we can work on it with this thread,
Using the browser's Network Inspector what is the JSON response? Can you paste it here?
Kevin
And here is the response from server
{
"data":[
{
"id":"\u003ccenter\u003e1\u003c/center\u003e",
"name":"vaxaca8206@ismailgul.net",
"email":"vaxaca8206@ismailgul.net",
"invoices_count":"\u003ccenter\u003e0\u003c/center\u003e",
"paid_invoices":"\u003ccenter\u003e0\u003c/center\u003e",
"pay_me_page":"\u003ca href='/page-1' target='_blank'\u003epage-1\u003c/a\u003e",
"created_at":"\u003ccenter\u003e04/07/20\u003c/center\u003e",
"stripe":"\u003ccenter\u003eNo\u003c/center\u003e",
"coinbase":"\u003ccenter\u003eNo\u003c/center\u003e",
"signin_as":"\u003ca href='/admins/2/become' target='_blank'\u003eLogin\u003c/a\u003e",
"status":"\u003ca href='/admin/businesses/2/toggle-activation'\u003eDeactivate\u003c/a\u003e"
},
{
"id":"\u003ccenter\u003e2\u003c/center\u003e",
"name":"jilifen349@mailmyrss.com",
"email":"jilifen349@mailmyrss.com",
"invoices_count":"\u003ccenter\u003e0\u003c/center\u003e",
"paid_invoices":"\u003ccenter\u003e0\u003c/center\u003e",
"pay_me_page":"\u003ca href='' target='_blank'\u003e-\u003c/a\u003e",
"created_at":"\u003ccenter\u003e04/07/20\u003c/center\u003e",
"stripe":"\u003ccenter\u003eNo\u003c/center\u003e",
"coinbase":"\u003ccenter\u003eNo\u003c/center\u003e",
"signin_as":"\u003ca href='/admins/3/become' target='_blank'\u003eLogin\u003c/a\u003e",
"status":"\u003ca href='/admin/businesses/3/toggle-activation'\u003eDeactivate\u003c/a\u003e"
}
],
"draw":1,
"recordsTotal":2,
"recordsFiltered":2
}
Can you also post the table initialisation code, please. These problems normally happen when the response doesn't match the declared columns.
Colin
If I follow the problem correctly the table loads fine initially then you sort and the response you posted is from the sort, correct?
If the above response is not from the initial load then there is a problem with the response. The
draw
parameter should not be1
. Its used as a sequence. You can read about it here. You can see how it works in this example by monitoring the Network requests and responses.Kevin
@kthorngren thank you so much. Yes i was passing wrong value of draw. You saved my day man. Thank you so much