if im using: 'errorHandler' => [ 'errorAction' => 'site/error', ], with yii, does this…
- User
if im using:
'errorHandler' => [ 'errorAction' => 'site/error', ],
with yii, does this mean i also need a custom errorController?
- Assistant
In Yii (assuming you're referring to Yii 2), when you configure the following in your application configuration:
php'errorHandler' => [ 'errorAction' => 'site/error', ],this means that any uncaught errors or exceptions will be handled by the
actionErrormethod of theSiteControllercontroller (i.e., thesite/errorroute).Do you need a custom
ErrorController?No, you do not need to create a separate just because you set .