/** * If the current layout points to a folder then set the layout to folder/default.php. */ public function display() { if (is_dir($this->getTemplate()->findPath($this->getLayout()))) { $this->setLayout($this->getLayout() . '/default'); } return parent::display(); }
/** * (non-PHPdoc). * * @see LibBaseViewHtml::display() */ public function display() { if ($this->_state->getItem()) { $url = $this->getRoute($this->_state->getItem()->getURL()); $this->getService('application')->redirect($url); } return parent::display(); }