I have 12 datatables:
<table id = "TABLE_1" class = "table table-striped">
<table id = "TABLE_2" class = "table table-striped">
I need to display datatables with export and visibility buttons.
This is the datatables-init.js file
$(document).ready(function() {
var table = $("table[id^='TABLE']").DataTable( {
buttons: ['copy', 'excel', 'pdf', 'colvis']
});
table.buttons().container()
.appendTo(table.DataTable()('.col-md-6:eq(0)'));
} );
The buttons do not display, I know that this is a problem with the place where they are displayed. Can anyone help ?