[SOLVED] zii.widgets.grid.CGridView, CButtonColumn

Hi guys, I have a problem when I created CButtonColumn just to using view.

Here’s my code :

<?php $this->widget('zii.widgets.grid.CGridView', array(

			'itemsCssClass'=>'table table-striped table-bordered table-hover',














When I ran it, it show error.

Trying to get property of non-object

error : eval()'d code(1)

I’ve tried to solve it. I used source code like this :



But it still showed error result again.

I hope anybody help me.

I don’t remember where to find a good example of how to configure CGridview.

Check out the first post in this thread.

Did you try to remove the code below?


Thank you for your answer :)

Thank you, but that was not about header. I’ve gotten the way to fix it. I just mixed :


      				  'viewButtonUrl'=>'Yii::app()->controller->createUrl("/task/view",array("id"=>$data["id"]))', 'template'=>'{view}',


. It solved. Thank you :)