I am using jQuery DataTables @version 1.10.11
All thing is work but column Filter not working. what is the issue?
is there external plug-in required or file?
Please help.
$(document).ready(function(){
$('#clist').dataTable({
"ordering": true,
"searching": false,
"order": [[ 0, "asc" ]],
"dom": 'rt<"bottom"lip>',
"columnDefs": [
{
"targets": [ 0 ],
"visible": false,
}, {
"targets": [ 2 ],
"orderable": false,
}, {
"targets": [ 3 ],
"orderable": false,
}, {
"targets": [ 4 ],
"orderable": false,
}
]
})
.columnFilter({
//sPlaceHolder: "head:after",
aoColumns: [
{ type: "text" },
{ type: "select", values: [ 'val1', 'val2', 'val3', 'val4'] },
{ type: "select", values: [ 'val1', 'val2', 'val3', 'val4'] },
null
]
});
});
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<script src="//cdn.datatables.net/1.10.11/js/jquery.dataTables.min.js"></script>
You need to include
jquery.dataTables.columnFilter.js
for columnFilter plugin, see Downloads page.See this jsFiddle for code and demonstration.