framework/web/Response.php
public function init()
    {
        if ($this->version === null) {
            if (isset($_SERVER['SERVER_PROTOCOL']) && $_SERVER['SERVER_PROTOCOL'] === 'HTTP/1.0') {
                $this->version = '1.0';
            } else {
                $this->version = '1.1';
            }
        }
        if ($this->charset === null) {
            $this->charset = Yii::$app->charset;
        }
        $this->formatters = array_merge($this->defaultFormatters(), $this->formatters);
    }
public function init()
    {
        if ($this->version === null) {
            if (isset($_SERVER['SERVER_PROTOCOL']) && $_SERVER['SERVER_PROTOCOL'] === 'HTTP/1.0') {
                $this->version = '1.0';
            } else {
                $this->version = '1.1';
            }
        }
        if ($this->charset === null) {
            $this->charset = Yii::$app->charset;
        }
        $this->formatters = array_merge($this->defaultFormatters(), $this->formatters);
    }
public function init ( ) { if ( $ this -> version === null ) { if ( isset ( $ _SERVER [ 'SERVER_PROTOCOL' ] ) && $ _SERVER [ 'SERVER_PROTOCOL' ] === 'HTTP/1.0' ) { $ this -> version = '1.0' ; } else { $ this -> version = '1.1' ; } } if ( $ this -> charset === null ) { $ this -> charset = Yii :: $ app -> charset ; } $ this -> formatters = array_merge ( $ this -> defaultFormatters ( ) , $ this -> formatters ) ; }
Initializes this component.
Initializes this component .