Exemplo n.º 1
0
 /**
  * Подключение события
  * @param CComponent $owner - 'хозяин' события
  * @return void
  */
 public function attach($owner)
 {
     $this->lm = $owner->getUrlManager();
     if (is_array($this->lm->languages) && count($this->lm->languages) > 1) {
         $owner->attachEventHandler('onBeginRequest', [$this, 'handleLanguageBehavior']);
     }
 }