Change the color in a specific line
Change the color in a specific line
thomas-99
Posts: 7Questions: 1Answers: 0
How can I change the background color in a row if a record has a specific status?
Thank you
This discussion has been closed.
Answers
Take a look at
createdRow
. The examples should help.Kevin
Hi @thomas-99 ,
Here's another example to look at too,
Cheers,
Colin
Hi Colin,
Thank you. When I want to display data, always comes: undefined
$('#example').dataTable( {
"createdRow": function( row, data, dataIndex ) {
console.log(data[1]);
}
}
} );
if i just enter data, the whole array comes up
DT_RowId: "row_12251"
Name: "tester1"
Land: "Deutschland"
Firma: ""
Name: "tester1"
....
Why will not the array output?
Ciao Thomas
Hi Thomas,
It's most likely because you're using objects, the example on that page is used an array. Take a look at the example here, it's modified to use objects,
Cheers,
Colin