What is the JSON data for fnReloadAjax supposed to look like?
What is the JSON data for fnReloadAjax supposed to look like?
rkorebrits
Posts: 8Questions: 1Answers: 0
Hi there,
We are currently refreshing pages when we are adding data to a table, but instead we want to use the fnReloadAjax function to get the data smarter. I however haven't been able to find any info of what the AJAX source is supposed to look like. I assume the data is JSON?
Is it just an array of objects, with the same count of items in an object as columns in a table?
We are currently refreshing pages when we are adding data to a table, but instead we want to use the fnReloadAjax function to get the data smarter. I however haven't been able to find any info of what the AJAX source is supposed to look like. I assume the data is JSON?
Is it just an array of objects, with the same count of items in an object as columns in a table?
This discussion has been closed.
Replies
[code]
{
"aaData": [
[... row 1...],
[... row 2...],
[... row 3...]
]
}
[/code]
But using mData you can have an array of objects returns and with sAjaxDataProp you can return just an array or change the `aaData` to anything you want.
Allan
[code]
{
"aaData": [
["1", "Richard", "Lorem"],
["2", "Allan", "Ipsum"]
]
}
[/code]