/**
  * Initialize $this->view (unless already initialized) and return it.
  * @return waSmarty3View
  */
 protected function getView()
 {
     if (!$this->view) {
         $this->view = waSystem::getInstance()->getView();
         $this->view->assign('action', $this);
     }
     return $this->view;
 }
 public function display()
 {
     if ($this->layout && $this->layout instanceof waLayout) {
         $this->layout->setBlock('content', $this->view->fetch($this->getTemplate()));
         $this->layout->display();
     } else {
         waSystem::getInstance()->getResponse()->sendHeaders();
         $this->view->display($this->getTemplate());
     }
 }
 public function display()
 {
     $this->execute();
     $this->view->assign($this->blocks);
     waSystem::getInstance()->getResponse()->sendHeaders();
     $this->view->cache(false);
     if ($this->view->autoescape() && $this->view instanceof waSmarty3View) {
         $this->view->smarty->loadFilter('pre', 'content_nofilter');
     }
     $this->view->display($this->getTemplate());
 }
Example #4
0
 public function display()
 {
     $this->execute();
     $this->view->assign($this->blocks);
     if (wa()->getEnv() == 'frontend' && waRequest::param('theme_mobile') && waRequest::param('theme') != waRequest::param('theme_mobile')) {
         wa()->getResponse()->addHeader('Vary', 'User-Agent');
     }
     wa()->getResponse()->sendHeaders();
     $this->view->cache(false);
     if ($this->view->autoescape() && $this->view instanceof waSmarty3View) {
         $this->view->smarty->loadFilter('pre', 'content_nofilter');
     }
     $this->view->display($this->getTemplate());
 }