yii\base\Controller::renderContent PHP Метод

renderContent() публичный Метод

Renders a static string by applying a layout.
С версии: 2.0.1
public renderContent ( string $content ) : string
$content string the static string being rendered
Результат string the rendering result of the layout with the given static string as the `$content` variable. If the layout is disabled, the string will be returned back.
    public function renderContent($content)
    {
        $layoutFile = $this->findLayoutFile($this->getView());
        if ($layoutFile !== false) {
            return $this->getView()->renderFile($layoutFile, ['content' => $content], $this);
        } else {
            return $content;
        }
    }