I'd like to add an icon to the left side of the text in the buttons for my DataTable, but it's not showing up so far. This is the Javascript I have for the Add button:
var buttons;
$.fn.dataTable.ext.buttons.add = {
className: 'button-add',
text: '<i class="dt-button button-add"></i> Add Branch',
action: function (dt) {
onBtnAddClicked()
}
};
And in CSS:
.fn.dataTable.ext.buttons.add.button-add span{
background: url(../img/icn_add.png) no-repeat center left;
}