Hi all,
I am using the datatables Buttons plugin to export to pdf. I am able to use custom styling to the button using the following code :
"processing": true, // for show progress bar
"serverSide": false, // for process server side
"dom": '<"top"i>rt<"bottom"lp><"clear">',
"scrollY": "500px",
"buttons": [
{ "extend": 'pdf', "text":'Export',"className": 'btn btn-default btn-xs' }
],
and this code to append the button to a <span> :
"initComplete": function() {
oTable.buttons().container()
.appendTo($('#btnPdf'));
However I am unable to find a way to use the bootstrap glyphicon with the button as I am using with my other input buttons as shown below :
<button type="button" value="Search" id="btnSearch" class="btn btn-default btn-xs"><span class="glyphicon glyphicon-search"></span>Search</button>
<button type="button" value="Clear" id="btnClear" class="btn btn-default btn-xs"><span class="glyphicon glyphicon-remove"></span>Clear</button>
<span id="btnPdf"></span>
Has anyone done something similar using the buttons plugin and icons/bootstrap glyphicons ?
Thanks in advance.