public function addLayout($name)
    {
        if (!$this->template) {
            return;
        }
        // TODO: change to functionExists()
        if (method_exists($this, $lfunc = 'layout_'.$name)) {
            if ($this->template->is_set($name)) {
                $this->$lfunc();
            }
        }

        return $this;
    }
public function addLayout($name)
    {
        if (!$this->template) {
            return;
        }
        // TODO: change to functionExists()
        if (method_exists($this, $lfunc = 'layout_'.$name)) {
            if ($this->template->is_set($name)) {
                $this->$lfunc();
            }
        }

        return $this;
    }
public function addLayout ( $ name ) { if ( ! $ this -> template ) { return ; } // TODO: change to functionExists() if ( method_exists ( $ this , $ lfunc = 'layout_' . $ name ) ) { if ( $ this -> template -> is_set ( $ name ) ) { $ this -> $ lfunc ( ) ; } } return $ this ; }
Register new layout, which, if has method and tag in the template, will be rendered.

@param string $name

@return $this
Register new layout which if has method and tag in the template will be rendered .