Пример #1
0
 public static function get($sector_path)
 {
     $r = RenderingStack::peek();
     if ($r->is_set($sector_path)) {
         return $r->get($sector_path);
     } else {
         throw new IllegalStateException("Il settore " . $sector_path . " non e' stata definita.");
     }
 }
Пример #2
0
 public static function clear()
 {
     self::$stack = array();
 }
Пример #3
0
 public function render()
 {
     RenderingStack::push(PageData::instance());
     include $this->__page_path;
     RenderingStack::pop();
 }
Пример #4
0
function render_path_result($path)
{
    return render_result(RenderingStack::peek()->get($path));
}
Пример #5
0
 public function render()
 {
     if (!$this->is_cached()) {
         $this->process();
     }
     $final_include_layout_path = substr($this->get_cached_layout_path(), 1);
     ob_start();
     include $final_include_layout_path;
     $rendered_content = ob_get_contents();
     ob_end_clean();
     RenderingStack::push($this->tree_view);
     echo $rendered_content;
     RenderingStack::pop();
 }