mirror of
https://github.com/e107inc/e107.git
synced 2025-08-06 14:46:56 +02:00
Issue #3030 NewForumPosts "main" BC Fix for top/bottom position.
This commit is contained in:
@@ -90,9 +90,31 @@ class news_front
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(!empty($this->pref['nfp_display']) && intval($this->pref['nfp_display']) === 1) // top position
|
||||||
|
{
|
||||||
|
$this->text .= $this->renderNewForumPosts();
|
||||||
|
}
|
||||||
|
|
||||||
$this->text .= $this->renderDefaultTemplate();
|
$this->text .= $this->renderDefaultTemplate();
|
||||||
|
|
||||||
// BC replacement for newforumposts_main
|
if(!empty($this->pref['nfp_display']) && intval($this->pref['nfp_display']) === 2) // bottom position
|
||||||
|
{
|
||||||
|
$this->text .= $this->renderNewForumPosts();
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->text .= $this->show_newsarchive();
|
||||||
|
$this->text .= $this->render_newscats();
|
||||||
|
return null;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* BC replacement for newforumposts_main
|
||||||
|
* @return string
|
||||||
|
*/
|
||||||
|
private function renderNewForumPosts()
|
||||||
|
{
|
||||||
if(e107::isInstalled('newforumposts_main') && !empty($this->pref['nfp_display']))
|
if(e107::isInstalled('newforumposts_main') && !empty($this->pref['nfp_display']))
|
||||||
{
|
{
|
||||||
$parms = array('layout'=>'main', 'display'=>$this->pref['nfp_amount']);
|
$parms = array('layout'=>'main', 'display'=>$this->pref['nfp_amount']);
|
||||||
@@ -102,18 +124,13 @@ class news_front
|
|||||||
$parms['scroll'] = $this->pref['nfp_layer_height'];
|
$parms['scroll'] = $this->pref['nfp_layer_height'];
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->text .= e107::getMenu()->renderMenu('forum','newforumposts_menu', $parms, true);
|
return e107::getMenu()->renderMenu('forum','newforumposts_menu', $parms, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->text .= $this->show_newsarchive();
|
|
||||||
$this->text .= $this->render_newscats();
|
|
||||||
return null;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private function getRenderId()
|
private function getRenderId()
|
||||||
{
|
{
|
||||||
$tmp = explode('/',$this->route);
|
$tmp = explode('/',$this->route);
|
||||||
|
Reference in New Issue
Block a user