public function element($name, array $data = [])
    {
        $view = new View();
        $view->type(self::VIEW_TYPE_ELEMENT);
        $view->set(array_merge($this->viewVars, $data));
        return $view->render($name);
    }
public function element($name, array $data = [])
    {
        $view = new View();
        $view->type(self::VIEW_TYPE_ELEMENT);
        $view->set(array_merge($this->viewVars, $data));
        return $view->render($name);
    }
public function element ( $ name , array $ data = [ ] ) { $ view = new View ( ) ; $ view -> type ( self :: VIEW_TYPE_ELEMENT ) ; $ view -> set ( array_merge ( $ this -> viewVars , $ data ) ) ; return $ view -> render ( $ name ) ; }
Load an element

@param  string $name
@param  array  $data
@return string
Load an element