diff --git a/config/loader.php b/config/loader.php index 4e43a577..6d6c9bc7 100644 --- a/config/loader.php +++ b/config/loader.php @@ -167,4 +167,11 @@ if($aPluginsList=@file($sPluginsListFile)) { } } } + +/** + * Загружает конфиг текущего шаблона + */ +if(file_exists(Config::Get('path.smarty.template').'/settings/config/config.php')) { + Config::LoadFromFile(Config::Get('path.smarty.template').'/settings/config/config.php',false); +} ?> \ No newline at end of file diff --git a/engine/modules/viewer/Viewer.class.php b/engine/modules/viewer/Viewer.class.php index 4d09374d..4d074e9a 100644 --- a/engine/modules/viewer/Viewer.class.php +++ b/engine/modules/viewer/Viewer.class.php @@ -654,8 +654,6 @@ class ModuleViewer extends Module { } } } - - $this->aFileRules = Config::Get('head.rules'); } /** * Создает css-компрессор и инициализирует его конфигурацию @@ -718,6 +716,7 @@ class ModuleViewer extends Module { */ $aResult = $this->aFilesDefault; + $this->aFileRules = Config::Get('head.rules'); foreach((array)$this->aFileRules as $sName => $aRule) { if(!$aRule['path']) continue;