I using jquery datatable plugin and having a "Create" button for ajax creation of my db instance. I wish to reload the datatable after the db instance is created, and i spend for more than one day just to find a solution for this. The closest thing i could find is the plugin for DataTables - fnReloadAjax, however, i cant get it to work. I get either error like: fnReloadAjax is not a function OR networkerror: null124234242 is not found (in firebug)
Any idea how can i reload the table so user can get to see the newly inserted data without refreshing the page??
// Initialize data table
var myTable = $('#stocktable').dataTable({
// Try styling
"sScrollX": "100%",
"sScrollXInner": "100%",
"bScrollCollapse": true,
// To use themeroller theme
"bJQueryUI": true,
// To use TableTool plugin
"sDom": 'T<"clear">lfrtip',
// Allow single row to be selected
"oTableTools": {
"sRowSelect": "single"
}
// Use dataTable editable plugin to allow ajax delete
}).makeEditable({
// Reference to controller action
//sAddURL: "/Stock/AddData",
sDeleteURL: "/Stock/DeleteData",
sDeleteHttpMethod: "GET"
});
When i try to call myTable.fnReloadAjax(), i get the error.. Really need help here... Thanks...