From e25316d95f73537edb68471dc79c0221defae464 Mon Sep 17 00:00:00 2001 From: Cameron Date: Sun, 18 Dec 2016 07:55:37 -0800 Subject: [PATCH] Fix for news pagination. --- e107_plugins/news/news.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/e107_plugins/news/news.php b/e107_plugins/news/news.php index d9be40c21..4d714795e 100644 --- a/e107_plugins/news/news.php +++ b/e107_plugins/news/news.php @@ -156,25 +156,25 @@ class news_front private function setRoute() { - $newsUrlparms = array('page' => '--FROM--'); + $this->newsUrlparms = array('page' => '--FROM--'); if($this->subAction) { switch ($this->action) { case 'list': - $newsUrlparms['id'] = $this->subAction; + $this->newsUrlparms['id'] = $this->subAction; $newsRoute = 'list/category'; break; case 'cat': - $newsUrlparms['id'] = $this->subAction; + $this->newsUrlparms['id'] = $this->subAction; $newsRoute = 'list/short'; break; case 'day': case 'month': - $newsUrlparms['id'] = $this->subAction; + $this->newsUrlparms['id'] = $this->subAction; $newsRoute = 'list/'.$this->action; break; @@ -186,7 +186,7 @@ class news_front elseif($this->action == 'all') { $newsRoute = 'list/all'; - $newsUrlparms['id'] = $this->subAction; + $this->newsUrlparms['id'] = $this->subAction; } else { @@ -816,7 +816,7 @@ class news_front $parms = 'tmpl_prefix='.deftrue('NEWS_NEXTPREV_TMPL', 'default').'&total='.$news_total.'&amount='.$amount.'¤t='.$this->from.$nitems.'&url='.$url; - // e107::getDebug()->log($newsUrlparms); + $this->addDebug('newsUrlParms',$this->newsUrlparms); $text .= $tp->parseTemplate("{NEXTPREV={$parms}}"); @@ -1509,7 +1509,7 @@ class news_front $newsObj = new news_front; require_once(HEADERF); $newsObj->render(); -if(E107_DBG_BASIC) +if(E107_DBG_BASIC && ADMIN) { $newsObj->debug(); }