1
0
Fork 0
mirror of https://github.com/Oreolek/ifhub.club.git synced 2024-05-20 17:58:24 +03:00

Поддержка загрузки конфига шаблона из каталога settings/config/, например, /templates/skin/new/settings/config/config.php

This commit is contained in:
Mzhelskiy Maxim 2010-06-02 16:29:09 +00:00
parent de59cba7a0
commit 0fc43f914f
2 changed files with 8 additions and 2 deletions

View file

@ -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);
}
?> ?>

View file

@ -654,8 +654,6 @@ class ModuleViewer extends Module {
} }
} }
} }
$this->aFileRules = Config::Get('head.rules');
} }
/** /**
* Создает css-компрессор и инициализирует его конфигурацию * Создает css-компрессор и инициализирует его конфигурацию
@ -718,6 +716,7 @@ class ModuleViewer extends Module {
*/ */
$aResult = $this->aFilesDefault; $aResult = $this->aFilesDefault;
$this->aFileRules = Config::Get('head.rules');
foreach((array)$this->aFileRules as $sName => $aRule) { foreach((array)$this->aFileRules as $sName => $aRule) {
if(!$aRule['path']) continue; if(!$aRule['path']) continue;