My jSON response works good at localhost but in server throws error.
My jSON response works good at localhost but in server throws error.
manigopal
Posts: 11Questions: 3Answers: 0
At localhost it works fine but at server hosted.,
DataTables warning: table id=user_data - Invalid JSON response. For more information about this error, please see http://datatables.net/tn/1
Hosted URL : http://basicajaxcrud.22web.org/
This discussion has been closed.
Answers
Have you followed the diagnostic steps shown in the error? I just did, and it shows the Ajax response from
fetch.php
is empty - which is indeed an invalid JSON response. You'll need to check the server scripts to determine why that is happening.Colin
Hi Colin
Even I'm too facing the same issue .
Its working fine with other DB environments but I'm facing problem with prod Db alone.
But the interesting part is the issue gets fixed automatically on its own in 3 or days .after some time it emerges again .
Could you please suggest
Thanks,
Swapnil
As with the OP, the key is to follow the diagnostic steps. If it's failing intermittently, then the issue will be with the server - so it would be worth checking logs there and comparing the output on the good and bad days,
Colin