我正在将jquery datatable整合到我的项目中。当调用服务时,一些如何跟随错误抛出错误
这是代码
时间线
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script> <script src="js/jquery.dataTables.js"></script>
<body> <script> $(document).ready( function() { $('#example').dataTable( { "bProcessing": true,"bServerSide": true,"sAjaxSource": "URL","fnServerData": function ( sSource,aoData,fnCallback,oSettings ) { console.log(aoData); oSettings.jqXHR = $.ajax( { "dataType": 'json',"type": "POST","url": sSource,"data": aoData,"success": fnCallback } ); } } ); } ); </script> <div id="dvContent"> <table cellpadding="0" cellspacing="0" border="0" id="example"> </table> </div> </body>
这是服务器的样品输出
{ “一些”: “YYY”
“开放”:空,
“节目”:1,
“多”:“必须”,
“意见”:000
}