http://codeigniter.com/forums/viewthread/160896/P30/#833732
my javascript in header is as follow
[removed]
$(document).ready(function() {
$(’#example’).dataTable( {
“bProcessing”: true,
“aaSorting”: [[ 1, “desc” ]],
“bServerSide”: true,
“sAjaxSource”: “<?php echo base_url(); ?>poli/poliumumlist”,
“sScrollY”: 200,
“bJQueryUI”: true,
“sPaginationType”: “full_numbers”
} );
} );
function fnShowHide( iCol ) {
var oTable = $(’#example’).dataTable();
var bVis = oTable.fnSettings().aoColumns[iCol].bVisible;
oTable.fnSetColumnVis( iCol, bVis ? false : true );
}
[removed]
the result from /poli/poliumumlist is a below
{“sEcho”:0,“iTotalRecords”:“4”,“iTotalDisplayRecords”:“4”,“aaData”:[[“7”,“24 Jan 2012”,“005000430”,“Sutono”,“L”,“41”,“Ya”,null],[“2”,“24 Jan 2012”,“005000110”,“Sudrajat”,“L”,“31”,“Ya”,“Mario”],[“1”,“23 Jan 2012”,“005000120”,“Sutini”,“P”,“22”,“Ya”,“Isabel”],[“6”,“23 Dec 2011”,“099000231”,“Agung”,“L”,“27”,“Ya”,“Mario”]]}
