I have a CGridView table. I would like to add data-id attribute to the <td> element. Looking at the CDataColumn I have the following column:
htmlOptions from the above code fail as $model->article_id is null. How can I access the value of the current data row?
Thanks
'columns'=>array(
array(
'name' => 'article_title',
'value' => '$data->article_id . ". " . $data->article_title',
'htmlOptions' => array("data-id" => $model->article_id),
)
),
htmlOptions from the above code fail as $model->article_id is null. How can I access the value of the current data row?
Thanks