mirror of
https://github.com/e107inc/e107.git
synced 2025-08-12 09:34:54 +02:00
Forum now utilizes THEME_LEGACY check for template loading.
This commit is contained in:
@@ -309,28 +309,33 @@ str_replace("[x]", ($total_topics+$total_replies), LAN_FORUM_0031)." ($total_top
|
||||
|
||||
|
||||
|
||||
|
||||
if(empty($FORUM_TEMPLATE))
|
||||
{
|
||||
// include(e_PLUGIN.'forum/templates/forum_template.php');
|
||||
|
||||
// Override with theme template
|
||||
if (file_exists(THEME.'forum_template.php')) //v1.x fallback.
|
||||
if(THEME_LEGACY !== true) //v2.x
|
||||
{
|
||||
$FORUM_TEMPLATE = e107::getTemplate('forum','forum'); // required to use v2.x wrapper shortcode wrappers.
|
||||
}
|
||||
elseif (file_exists(THEME.'forum_template.php')) //v1.x fallback.
|
||||
{
|
||||
include(e_PLUGIN.'forum/templates/forum_template.php');
|
||||
include_once(THEME.'forum_template.php');
|
||||
}
|
||||
elseif(file_exists(THEME.'templates/forum/forum_template.php'))
|
||||
{
|
||||
$FORUM_TEMPLATE = e107::getTemplate('forum','forum');
|
||||
// $FORUM_TEMPLATE = e107::getTemplate('forum','forum');
|
||||
require_once(THEME.'templates/forum/forum_template.php');
|
||||
}
|
||||
else //v2.x
|
||||
else
|
||||
{
|
||||
$FORUM_TEMPLATE = e107::getTemplate('forum','forum'); // required to use v2.x wrapper shortcode wrappers.
|
||||
require_once(e_PLUGIN.'forum/templates/forum_template.php');
|
||||
}
|
||||
}
|
||||
|
||||
if(is_array($FORUM_TEMPLATE)) // new v2.x format.
|
||||
if(is_array($FORUM_TEMPLATE) && THEME_LEGACY !== true) // new v2.x format.
|
||||
{
|
||||
|
||||
if(varset($FORUM_TEMPLATE['main-start'])) // correction of previous v2.x setup.
|
||||
|
Reference in New Issue
Block a user