412 (Precondition Failed) when set no cache in fnServeData

412 (Precondition Failed) when set no cache in fnServeData

lawrancelawrance Posts: 3Questions: 0Answers: 0
edited February 2013 in DataTables 1.9
I add "fnServerData" to set false to data cache, I couln't load the the data I got an HTTP error 412 (Precondition Failed)
can you help please
here is part of the code
[code]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">



<!////////////////////////////////////////////include section/////////////////////////////////////////////////!>


Monitor

@import "DataTables-1.9.1/media/css/demo_page.css";
@import "DataTables-1.9.1/media/css/demo_table.css";
@import "css/innerhtml.css" ;

<!--[if gte IE 9 ]><![endif]-->
<!--[if !IE]>--><!--<![endif]-->





///////////////////////////////////////////////////////////Ready///////////////////////////////////////////////////
$(document).ready(function() {
var anOpen = [];
var cbs = [];
var hold = 0 ;
var sImageUrl = "DataTables-1.9.1/examples/examples_support/";
//refresh every 30sec
var oTable = $('#run_plan').dataTable( {
"bProcessing": true,
"bServerSide" : false,
//this save the cookies of the session
"bStateSave": true ,
"sAjaxSource": "data/run_plan.txt",
//added to override the json loader to set cache false
"fnServerData": function ( sSource, aoData, fnCallback, oSettings ) {
oSettings.jqXHR = $.ajax( {
"dataType": 'json',
"cache": 'false',
"type": "POST",
"url": sSource,
"data": aoData,
"success": fnCallback
} );
},

[/code]
This discussion has been closed.