Hi to all,
I’m new to Yii and have a problem with a widget I made.
I have an action which generates an image, added the action to my sitecontroller and like the to display the image in the widget with
$myAction ='myaction';
public function run()
{
$url=$this->getController()->createUrl($this->myAction,array('v'=>uniqid()));
CHtml::image( $url,'');
}
But the image is never displayed. The widget run function is called, but it seems that the controller is not calling my action.
When I enter ‘localhost/index.php?r=site/myaction’ in the browser everything works fine, the image is displayed, what means that the action class is called by the controller and is working as expected.
I tried than this extension ETextImage but it seems that there is the same issue.
What could be the problem here?
Thanks in advance
Frank