How to export innerHTML Values only

How to export innerHTML Values only

sr13579sr13579 Posts: 1Questions: 1Answers: 0

There is something that I was working on and I needed to export everything in CSV. I was working on AJAX loading. Here is the data part:
{ data: 'id },
{ data: 'mode' },
{ data: 'name' },
I then put a Serial number with:
{ data:'id',
"fnCreatedCell":(nTd, sData, oData, iRow, iCol)=>{
$(nTd).html(iRow+1)
} },
This far everything is okay. But With button plugin when I try to export a CSV It is not giving me Serial Number. It is giving me those ID numbers from database and they are not in serial. What I want is:
1,2,3,4,5,6,7.....
And it is giving me
23,45,46,47,50....... In CSV
How can I get the normal Serial Number in CSV file after export?

Answers

Sign In or Register to comment.