I have datepickers in the header of my DataTable. I need 2 things here.
One, the same exact datepickers that are working outside the table will not work within the header (or include calendar icons). I've tried implementing these via DOM as well, which still didn't work and this way seems less messy.
Two, these datepickers should act as a filter for the table. So From October 2, To October 4 should hide all dates outside that bracket. Any ideas? Thanks in advance.
jQuery
$(".datepick").datepicker({
showOn: "both",
buttonImage: "http://www.effinghamparkdistrict.org/graphics/calendar_icon.png"
});
$('#example').dataTable({
"bJQueryUI": true,
"sPaginationType": "full_numbers",
"aLengthMenu": [
[5, 10, 15, 20, -1],
[5, 10, 15, 20, "All"]
],
"iDisplayLength": 10
});
$("<div class='nBreak padR'><label>Date Filter:</label> From <input type='text' class='datepick' /> To <input type='text' class='datepick' /></div>").prependTo('div.dataTables_filter');