Invalid JSON response
Invalid JSON response
Debug:- http://debug.datatables.net/aqolux
Hi all,
I'm not getting anything back after amending the code I used from SitePoint for a different table set up on the database. It was working for the IT Companies example linked below but I'm having no luck with it after amending the queries, forms, etc for my example.
When I check the XHR response when trying to get the questions (/data.php?job=get_questions&_=1474058523808) I'm getting no response but if I echo out a variable for two columns I'm getting back the question_ID and topic:
1-Biology2-Biology3- Biology4-Biology5-Biology6
SitePoint Reference: https://www.sitepoint.com/creating-a-scrud-system-using-jquery-json-and-datatables/
This question has an accepted answers - jump to answer
Answers
Thanks for the debug trace. If you click the "Tables" tab in the debugger via and then the "Server interaction" header, you will be able to see that the response from the server is indeed not valid JSON.
You'd need to modify your server-side script to return valid JSON.
Allan
There were issues with special characters in the sentences used. We had use the dataTable to add the questions in again and it was fine. For example, see below:
What’s the name of the channel that Krusty works for?
All is grand for the moment.