mirror of
https://github.com/e107inc/e107.git
synced 2025-08-07 15:16:30 +02:00
Fix custom page batch data overridden by custom menu (when menu is rendered before the page)
This commit is contained in:
12
page.php
12
page.php
@@ -59,10 +59,11 @@ else
|
|||||||
{
|
{
|
||||||
$e107CorePage->setRequest('showPage');
|
$e107CorePage->setRequest('showPage');
|
||||||
$e107CorePage->processViewPage();
|
$e107CorePage->processViewPage();
|
||||||
|
$e107CorePage->setPage();
|
||||||
|
|
||||||
require_once(HEADERF);
|
require_once(HEADERF);
|
||||||
|
|
||||||
echo $e107CorePage->showPage();
|
echo $e107CorePage->pageOutput['text'];
|
||||||
|
|
||||||
require_once(FOOTERF);
|
require_once(FOOTERF);
|
||||||
exit;
|
exit;
|
||||||
@@ -679,7 +680,7 @@ class pageClass
|
|||||||
return str_replace('[[PAGECOMMENTS]]', $comments, $this->cacheData['PAGE']);
|
return str_replace('[[PAGECOMMENTS]]', $comments, $this->cacheData['PAGE']);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function showPage()
|
public function setPage()
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
@@ -709,7 +710,9 @@ class pageClass
|
|||||||
|
|
||||||
if($vars->cachecontrol) $this->setCache($ret, $this->batch->sc_cpagetitle(), $this->page['page_comment_flag']);
|
if($vars->cachecontrol) $this->setCache($ret, $this->batch->sc_cpagetitle(), $this->page['page_comment_flag']);
|
||||||
|
|
||||||
return str_replace('[[PAGECOMMENTS]]', $this->batch->cpagecomments(), $ret);
|
//return str_replace('[[PAGECOMMENTS]]', $this->batch->cpagecomments(), $ret);
|
||||||
|
$this->pageOutput = array('text' => str_replace('[[PAGECOMMENTS]]', $this->batch->cpagecomments(), $ret));
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
$extend = new e_vars;
|
$extend = new e_vars;
|
||||||
@@ -749,7 +752,8 @@ class pageClass
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
return $this->renderPage($template, $extend);
|
// return $this->renderPage($template, $extend);
|
||||||
|
$this->pageOutput = array('text' => $this->renderPage($template, $extend));
|
||||||
}
|
}
|
||||||
|
|
||||||
public function renderPage($template, $vars = null)
|
public function renderPage($template, $vars = null)
|
||||||
|
Reference in New Issue
Block a user