Example #1
0
 public function __toString()
 {
     try {
         return (string) $this->render();
     } catch (Exception $e) {
         Eden_Error_Event::i()->exceptionHandler($e);
     }
     return '';
 }
Example #2
0
 public function __toString()
 {
     try {
         $response = (string) $this->registry()->get('response');
     } catch (Exception $e) {
         Eden_Error_Event::i()->exceptionHandler($e);
         $response = '';
     }
     return $response;
 }
Example #3
0
 public function __toString()
 {
     try {
         $output = $this->render();
     } catch (Exception $e) {
         Eden_Error_Event::i()->exceptionHandler($e);
         return '';
     }
     if (is_null($output)) {
         return '';
     }
     return $output;
 }
Example #4
0
if(!class_exists('Eden_Block')){abstract class Eden_Block extends Eden_Class{protected static $_blockRoot=NULL;private static $_global=array();public function __toString(){try{return (string) $this->render();}catch(Exception $e){Eden_Error_Event::i()->exceptionHandler($e);}return '';}abstract public function getTemplate();abstract public function getVariables();public function render(){return Eden_Template::i()->set($this->getVariables())->parsePhp($this->getTemplate());}public function setBlockRoot($root){Eden_Error::i()->argument(1,'folder');self::$_blockRoot=$root;return $this;}protected function _getGlobal($value){if(in_array($value,self::$_global)){return false;}self::$_global[]=$value;return $value;}}}