'app-frontend', 'basePath' => dirname(__DIR__), 'bootstrap' => ['log'], 'controllerNamespace' => 'frontend\controllers', 'components' => [ 'request' => [ 'baseUrl' => '', 'cookieValidationKey' => 'ndahjhjjidasuidrqeswuiuirqw89', 'csrfParam' => '_frontendCSRF', // 'class' => 'common\modules\language\components\LanguageRequest', ], 'user' => [ 'identityClass' => 'common\models\User', 'enableAutoLogin' => true, 'identityCookie' => ['name' => '_identity-frontend', 'httpOnly' => true], ], 'session' => [ // this is the name of the session cookie used for login on the frontend 'name' => 'advanced-frontend', ], 'log' => [ 'traceLevel' => YII_DEBUG ? 3 : 0, 'targets' => [ [ 'class' => 'yii\log\FileTarget', 'levels' => ['error', 'warning'], ], ], ], 'errorHandler' => [ 'errorAction' => 'site/error', ], 'urlManager' => [ 'enablePrettyUrl' => true, 'showScriptName' => false, // 'class'=>'common\modules\language\components\LanguageUrlManager', 'rules' => [ [ 'class' => '\common\modules\product\CatalogUrlManager', 'route_map' => [ 'catalog' => 'catalog/category', 'product' => 'catalog/product', ] ], '/' => 'site/index', '/'=>'/', ], ], 'language' => 'ru-RU', 'i18n' => [ 'translations' => [ '*' => [ 'class' => 'yii\i18n\PhpMessageSource', 'basePath' => '@frontend/messages', 'sourceLanguage' => 'en', ], ], ], ], 'params' => $params, ];