aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB')
-rw-r--r--phpBB/adm/index.php2
-rw-r--r--phpBB/adm/swatch.php2
-rw-r--r--phpBB/includes/functions_messenger.php2
-rw-r--r--phpBB/includes/functions_module.php2
-rw-r--r--phpBB/install/index.php2
-rw-r--r--phpBB/install/install_update.php2
-rw-r--r--phpBB/phpbb/template/template.php3
-rw-r--r--phpBB/phpbb/template/twig/twig.php13
8 files changed, 10 insertions, 18 deletions
diff --git a/phpBB/adm/index.php b/phpBB/adm/index.php
index c79327d22c..3520eb8b70 100644
--- a/phpBB/adm/index.php
+++ b/phpBB/adm/index.php
@@ -50,7 +50,7 @@ $module_id = request_var('i', '');
$mode = request_var('mode', '');
// Set custom style for admin area
-$template->set_custom_style('admin', $phpbb_admin_path . 'style', '');
+$template->set_custom_style('admin', $phpbb_admin_path . 'style');
$template->assign_var('T_ASSETS_PATH', $phpbb_root_path . 'assets');
$template->assign_var('T_TEMPLATE_PATH', $phpbb_admin_path . 'style');
diff --git a/phpBB/adm/swatch.php b/phpBB/adm/swatch.php
index ef89081dc8..cdd6bf3969 100644
--- a/phpBB/adm/swatch.php
+++ b/phpBB/adm/swatch.php
@@ -22,7 +22,7 @@ $auth->acl($user->data);
$user->setup();
// Set custom template for admin area
-$template->set_custom_style('admin', $phpbb_admin_path . 'style', '');
+$template->set_custom_style('admin', $phpbb_admin_path . 'style');
$template->set_filenames(array(
'body' => 'colour_swatch.html')
diff --git a/phpBB/includes/functions_messenger.php b/phpBB/includes/functions_messenger.php
index 89dd3c70fc..3a9e1fa77b 100644
--- a/phpBB/includes/functions_messenger.php
+++ b/phpBB/includes/functions_messenger.php
@@ -660,7 +660,7 @@ class messenger
{
$this->setup_template();
- $this->template->set_custom_style($path_name, $paths, '');
+ $this->template->set_custom_style($path_name, $paths);
}
}
diff --git a/phpBB/includes/functions_module.php b/phpBB/includes/functions_module.php
index c84e02afe6..8f0f6a837a 100644
--- a/phpBB/includes/functions_module.php
+++ b/phpBB/includes/functions_module.php
@@ -508,7 +508,7 @@ class p_master
if (is_dir($module_style_dir))
{
- $template->set_custom_style('admin', array($module_style_dir, $phpbb_admin_path . 'style'), '');
+ $template->set_custom_style('admin', array($module_style_dir, $phpbb_admin_path . 'style'));
}
}
diff --git a/phpBB/install/index.php b/phpBB/install/index.php
index f80b975e2c..84d751e279 100644
--- a/phpBB/install/index.php
+++ b/phpBB/install/index.php
@@ -213,7 +213,7 @@ $config = new phpbb_config(array(
));
$template = new phpbb_template_twig($phpbb_root_path, $phpEx, $config, $user, new phpbb_template_context());
-$template->set_custom_style('admin', $phpbb_admin_path . 'style', '');
+$template->set_custom_style('admin', $phpbb_admin_path . 'style');
$template->assign_var('T_ASSETS_PATH', '../assets');
$template->assign_var('T_TEMPLATE_PATH', $phpbb_admin_path . 'style');
diff --git a/phpBB/install/install_update.php b/phpBB/install/install_update.php
index 63f10c96d7..a105944fb3 100644
--- a/phpBB/install/install_update.php
+++ b/phpBB/install/install_update.php
@@ -138,7 +138,7 @@ class install_update extends module
}
// Set custom template again. ;)
- $template->set_custom_style('admin', $phpbb_admin_path . 'style', '');
+ $template->set_custom_style('admin', $phpbb_admin_path . 'style');
$template->assign_vars(array(
'S_USER_LANG' => $user->lang['USER_LANG'],
diff --git a/phpBB/phpbb/template/template.php b/phpBB/phpbb/template/template.php
index 8554365c95..9881938a8f 100644
--- a/phpBB/phpbb/template/template.php
+++ b/phpBB/phpbb/template/template.php
@@ -57,10 +57,9 @@ interface phpbb_template
*
* @param string|array $names Array of names or string of name of template(s) in inheritance tree order, used by extensions.
* @param array or string $paths Array of style paths, relative to current root directory
- * @param string $template_path Path to templates, relative to style directory. Default (template/).
* @return phpbb_template $this
*/
- public function set_custom_style($names, $paths, $template_path = 'template/');
+ public function set_custom_style($names, $paths);
/**
* Clears all variables and blocks assigned to this template.
diff --git a/phpBB/phpbb/template/twig/twig.php b/phpBB/phpbb/template/twig/twig.php
index 26f454e972..4aa1774ef4 100644
--- a/phpBB/phpbb/template/twig/twig.php
+++ b/phpBB/phpbb/template/twig/twig.php
@@ -225,7 +225,7 @@ class phpbb_template_twig implements phpbb_template
$this->twig->getLoader()->setPaths($paths, 'core');
}
- $this->set_custom_style($names, $paths, '');
+ $this->set_custom_style($names, $paths);
return $this;
}
@@ -237,10 +237,9 @@ class phpbb_template_twig implements phpbb_template
*
* @param string|array $names Array of names or string of name of template(s) in inheritance tree order, used by extensions.
* @param array or string $paths Array of style paths, relative to current root directory
- * @param string $template_path Path to templates, relative to style directory. Default (template/).
* @return phpbb_template $this
*/
- public function set_custom_style($names, $paths, $template_path = 'template/')
+ public function set_custom_style($names, $paths)
{
if (is_string($paths))
{
@@ -252,14 +251,8 @@ class phpbb_template_twig implements phpbb_template
$names = array($names);
}
- $style_paths = array();
- foreach ($paths as $path)
- {
- $style_paths[] = $path . '/' . ltrim($template_path, '/');
- }
-
// Set as __main__ namespace
- $this->twig->getLoader()->setPaths($style_paths);
+ $this->twig->getLoader()->setPaths($paths);
// Add all namespaces for all extensions
if ($this->extension_manager instanceof phpbb_extension_manager)