yii\web\Application::bootstrap PHP 메소드

bootstrap() 보호된 메소드

protected bootstrap ( )
    protected function bootstrap()
    {
        $request = $this->getRequest();
        Yii::setAlias('@webroot', dirname($request->getScriptFile()));
        Yii::setAlias('@web', $request->getBaseUrl());
        parent::bootstrap();
    }

Usage Example

예제 #1
0
파일: Application.php 프로젝트: semnt/tp01
 protected function bootstrap()
 {
     $this->i18n->addClassAlias('app/', "{$this->getBasePath()}/messages");
     parent::bootstrap();
     $this->language = 'ru-RU';
 }