/** * Retrieve view object * * @return \Zend\View\View */ public function getView() { if (null === $this->_view) { $options = $this->getOptions(); $this->_view = new \Zend\View\PhpRenderer($options); if (isset($options['doctype'])) { $this->_view->broker('doctype')->setDoctype(strtoupper($options['doctype'])); } } return $this->_view; }
/** * String representation of dojo environment * * @return string */ public function __toString() { if (!$this->isEnabled()) { return ''; } $this->_isXhtml = $this->view->broker('doctype')->isXhtml(); if (DojoHelper::useDeclarative()) { if (null === $this->getDjConfigOption('parseOnLoad')) { $this->setDjConfigOption('parseOnLoad', true); } } if (!empty($this->_dijits)) { $this->registerDijitLoader(); } $html = $this->_renderStylesheets() . PHP_EOL . $this->_renderDjConfig() . PHP_EOL . $this->_renderDojoScriptTag() . PHP_EOL . $this->_renderLayers() . PHP_EOL . $this->_renderExtras(); return $html; }