Display Jui Autosuggest In Cgridview

Hi, i am using JUI autosuggest in CGridView.

Here is the code

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






			'header' 	=> 	'',

			'name'		=>	'id',

			'class'		=>	'CCheckBoxColumn',

			'id' => 'selectedIds',

			'selectableRows' => '50',



				'header' 	=> 	'Vendor',

				'name'		=>	'rma_number',

				'value'		=>	function($data){ $this->widget('zii.widgets.jui.CJuiAutoComplete',array(


											"value"	=>	RepairInfo::model()->getRepairVendor($data->id, "name"),

										    "sourceUrl"	=>	array("Profiler/GetVendor"),


										    // additional javascript options for the autocomplete plugin









													"select"=>"js:function(event, ui) {





									echo CHtml::hiddenField("vendor$data->id", RepairInfo::model()->getRepairVendor($data->id, "id"), array("id" => "vendor$data->id", "name" => "vendor$data->id") );


				'type'		=>	'raw',



)); ?>

The problem is, it is working perfect on localhost but when i deploy it on server it generates error

"Fatal error: Using $this when not in object context in /project/file.php on line 161"

Please guide me, what is wrong with the code?


Please remove this widget and try other simple widget. First confirm whether widget problem or some other problem.

Seems that you can accessing a static method in your code which uses $this

thanks for you reply.

I am unable to understand, how it is working on localhost?

I have deployed (model, controller, view) but it is not working on server…

share the code of /project/file.php