isBanned($userRemoteAddress)){ echo Yii::t('common_v2', 'you are banned'); exit; } } function endRequest($event) { }findAll('setting_show_in_admin = 1'); if(!empty($settings)){ foreach ($settings as $k){ if(!defined($k->setting_name)){ define($k->setting_name, $k->setting_value); } } } Yii::app()->name = APP_NAME; Yii::app()->language = APP_LANG; Yii::app()->theme = APP_THEME; } }findAll('setting_show_in_admin = 1'); if(!empty($settings)){ foreach ($settings as $k){ if(!defined($k->setting_name)){ define($k->setting_name, $k->setting_value); } } } Yii::app()->name = APP_NAME; Yii::app()->language = APP_LANG; Yii::app()->theme = APP_THEME; } }