How to assign own CSS class name to cells?
How to assign own CSS class name to cells?
Similar to assigning rows their own IDs and CSS class names in http://datatables.net/release-datatables/examples/server_side/select_rows.html I was looking for such to be used with single cells.
Unfortunately search did not reveal any hint but I cannot imagine this not being in yet ?)
A sample JSON might look like
[code]
{
"version": "4",
"grade": { "sData": "A", "sClass": "customCssClass" },
"DT_RowId": "row_16",
"DT_RowClass": "gradeA"
},
[/code]
How to assign own CSS class name to cells?
Unfortunately search did not reveal any hint but I cannot imagine this not being in yet ?)
A sample JSON might look like
[code]
{
"version": "4",
"grade": { "sData": "A", "sClass": "customCssClass" },
"DT_RowId": "row_16",
"DT_RowClass": "gradeA"
},
[/code]
How to assign own CSS class name to cells?
This discussion has been closed.
Replies
Addressing individual cells in this manner is not something that DataTables currently support - although it is a candidate for inclusion in future. At the moment this can be achieved by using fnCreatedCell to assign the class from the data source object.
Allan