/** * render current view * @return type * @throws Exception */ public function renderView() { if (!$this->view) { throw new Exception(__METHOD__ . " set view first"); } $rhtml = $this->view->render(); return $rhtml; }
public function render($file = NULL) { if (is_null($this->_layout)) { return parent::render($file); } else { $this->content = parent::render($file); return parent::render($this->_layout); } }
/** * Renders the view object to a string. Global and local data are merged * and extracted to create local variables within the view file. * * Note: Global variables with the same key name as local variables will be * overwritten by the local variable. * * @throws View_Exception * @param view filename * @return string */ public function render($file = null, array $options = array()) { if ($this->_renderer == 'parent') { return parent::render($file); } if ($file !== null) { $this->set_filename($file); } if (empty($this->_file)) { throw new Kohana_View_Exception('You must set the file to use within your view before rendering'); } $method = 'Render_' . ucfirst($this->_renderer) . '::render'; return call_user_func($method, $this->_data, View::$_global_data, $this->_file, $options); }
public function render($file = NULL) { $file = parent::render($file); return $this->_markdown ? Markdown($file) : $file; }