frontend/controllers/SiteController.php
/**
     * Special page for display that site is under maintenance
     */
Special page for display that site is under maintenance
Special page for display that site is under maintenance
public function actionSystemFault()
    {
        $error_text = Yii::$app->session->get('system-fault-error', null);
        if ($error_text) {
            $this->layout = 'maintenance';
            Yii::$app->session->setFlash('error-system-fault', [
                'message' => Yii::t('app/flash-messages', $error_text),
                'type' => 'error',
                'ttl' => 0,
                'showClose' => false,
            ]);
            Yii::$app->session->set('system-fault-error', null);
            return $this->render('maintenance');
        } else {
            return $this->redirect(['/']);
        }
    }
public function actionSystemFault ( ) { $ error_text = Yii :: $ app -> session -> get ( 'system-fault-error' , null ) ; if ( $ error_text ) { $ this -> layout = 'maintenance' ; Yii :: $ app -> session -> setFlash ( 'error-system-fault' , [ 'message' => Yii :: t ( 'app/flash-messages' , $ error_text ) , 'type' => 'error' , 'ttl' => 0 , 'showClose' => false , ] ) ; Yii :: $ app -> session -> set ( 'system-fault-error' , null ) ; return $ this -> render ( 'maintenance' ) ; } else { return $ this -> redirect ( [ '/' ] ) ; } }
Special page for display that site is under maintenance
Special page for display that site is under maintenance