Normaly a ajax Datasource (for Datatables) looks like this:
"aaData": [
[ "Trident", "Internet Explorer 4.0", "Win 95+", 4, "X" ],
[ "Trident", "Internet Explorer 5.0", "Win 95+", 5, "C" ]
]
Is it possible to have a DOM response to an ajax request in Datatables ?
and have the server respond with html instead of Json ?
I would like to be able to just return the html:
<tr>
<td>cell 11</td> <td>cell 12</td>
</tr>
<tr>
<td>cell 21</td> <td>cell 22</td>
</tr>
This html example is a simplification, I want to return html because some of my columns are more complicated than just a simple text or date field.
NOTE:
I imagine this could be done with fnRowCallback, by generating the html code on the client side and using the normal Json response data, but it seems a bit unelegant to me.
I usually generate the code server side withouth problems and send the html back as json
in this way you generate the html serverside and then it gets inserted as is in the
<td>