Search the Community
Showing results for tags 'yii cgridview'.
I am using a CGridView with CActiveDataProvider. Everything works fine however now I have a need to show a custom button depending upon the id of the row. I can add the button and get it to work as well however I cannot customise the image according to the row id. I can see from examples that when creating url I can access the id of row by calling $data->id however when I try to do that for imageURL it does not work. My code is below: $this->widget('zii.widgets.grid.CGridView', array( 'dataProvider'=>$model->search(), 'filter'=>$model, 'columns'=>array( 'id',