Setting row id field

Setting row id field

pboissopboisso Posts: 7Questions: 0Answers: 0
edited December 2012 in DataTables 1.9
Hi,

Is there a way in the options of DataTables to set which field returned by the server is going to be used as the row id? I know DataTables uses DT_RowId as the default field, but would like to use a different field and cannot change response from server at this time.

Thanks.

Replies

  • allanallan Posts: 63,389Questions: 1Answers: 10,450 Site admin
    If you can't set DT_RowId you need to use fnCreatedRow as a callback to manipulate the TR element and add your id from your arbitrary data source.

    Allan
This discussion has been closed.