Problem in creating Other Class Object

Hi All,

It may sound very obvious question but I am not able to make other controller’s object in my second controller. I have successfully created and used objects of various models but unable to create an object of controller.

Whenever I try doing this I get an error YiiBase::include(Filename.php) failed to open stream

Any help…

Regards

Vatsal

Hi Vatsalpande,

Why would you like to get a reference to a controller? Please read http://www.yiiframework.com/doc/guide/1.1/en/basics.best-practices it will open your eyes and vision towards that.

Let the controller what is suppossed to do and try to use models for interacting with the database and build business logic. Create others that are required for certain app functionality and shared among…

Cheers man