Apply datatable tooltip to the datatable cell by jquery
<script type="text/javascript">
$(document).ready(function() {
$('#newcasemarktable tbody tr').each( function() {
var sTitle = "Tooltip heading";
var nTds = $('td', this);
this.setAttribute( 'title', sTitle );
} );
/* Init DataTables */
var newcasetable = $('#newcasemarktable').dataTable();
/* Apply the tooltips */
newcasetable.$('tr').tooltip( {
"delay": 0,
"track": true,
"fade": 250
} );
} );
</script>
you may use .on method for draw.dt event ==> used for after loading dataTable data.
$('#example').on( 'draw.dt', function () {
alert( 'Table redraw' );
} );
Comments
Post a Comment