Get row then first cell when using .cells().every() and current cell's data-attribute
Get row then first cell when using .cells().every() and current cell's data-attribute
punkilo
Posts: 1Questions: 1Answers: 0
I have this :-
Name | Grown | Space |
Sugar | 100 Kg | 100 sq.m |
Oil | 10 Lt | 21 sq.m |
Now I want is when I loop through the Grown column, i need to get name of the item (e.g. Sugar), data-value (100)
fancy_data_table.cells(".q").every( function () {
var data=this.data(); //this is data of the cell.
});
I am stuck here and the documetation didnt help me.
This discussion has been closed.
Answers
will get the data for the whole row.
It might be easiest if you use
rows().every()
though?Allan