As shown in the CGridView, the model for the current row is named “$data” and it’s somehow the only way to send some data to the view. And global variables, too. The problem is that CGridView eval’s the code (sent as a string) inside it’s class without having access to the parent controller (and view) and its data. So, no variables from the current view.
Regards,
Paul
PS: you also have access to “$row”, the zero based row number. Maybe you’ll find other variables if you study the CGridView class and make some tests.
Talking about widget rendering I found that the it gives the ‘htmlspecialchars’ error. I have a soft delete implemented in default scope and I solved the problem by adding ‘restore_error_handler();’ at the beginning of the function.