From e5061e2c018602cd4e42ec506ad6a2c1c68b074d Mon Sep 17 00:00:00 2001 From: Cameron Date: Wed, 12 Jun 2019 13:13:22 -0700 Subject: [PATCH] Experimental - render variable accumulator. --- class2.php | 7 +++++++ e107_core/templates/footer_default.php | 7 +++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/class2.php b/class2.php index 552908c15..bff09997c 100755 --- a/class2.php +++ b/class2.php @@ -947,6 +947,7 @@ if (!class_exists('e107table', false)) private $uniqueId = null; private $content = array(); private $contentTypes = array('header','footer','text','title','image', 'list'); + public $renders = array(); // all render vars. function __construct() @@ -1044,6 +1045,8 @@ if (!class_exists('e107table', false)) */ public function tablerender($caption, $text, $mode = 'default', $return = false) { + + $override_tablerender = e107::getSingleton('override', e_HANDLER.'override_class.php')->override_check('tablerender'); if ($override_tablerender) @@ -1118,6 +1121,10 @@ if (!class_exists('e107table', false)) $options['menuCount'] = $this->eMenuCount; $options['menuTotal'] = varset($this->eMenuTotal[$this->eMenuArea]); $options['setStyle'] = $this->eSetStyle; + $options['caption'] = $caption; + + $this->renders[] = $options; + if(is_object(vartrue($thm))) diff --git a/e107_core/templates/footer_default.php b/e107_core/templates/footer_default.php index bf734657a..cfcf9e276 100644 --- a/e107_core/templates/footer_default.php +++ b/e107_core/templates/footer_default.php @@ -397,11 +397,12 @@ if (!empty($pref['e_output_list']) && is_array($pref['e_output_list'])) //$length = ob_get_length(); //$page = ob_get_clean(); - +$search = array('{---CAPTION---}'); +$replace = array(print_a(e107::getRender()->renders,true)); // New - see class2.php $ehd = new e_http_header; -$ehd->setContent('buffer'); +$ehd->setContent('buffer', $search, $replace); $ehd->send(); // $ehd->debug(); @@ -413,6 +414,8 @@ $page = $ehd->getOutput(); // real output echo $page; + + unset($In_e107_Footer);