Reputation: 518
How can I use multi controller in one page? I used:
Yii::$app->controller->action();
How can I access another controllers?
Upvotes: 0
Views: 196
Reputation: 1160
You can create a new class and put your actions in the calass, after that create a object in the page you want to use it.
for example:
$object = new fontend\controllers\NewClassName;
$object -> YourAction();
Upvotes: 1