Содержимое файла | Последнее изменение | Открыть журнал | RSS
Редакция | Автор | № строки | Строка |
---|---|---|---|
304 | alex-w | 1 | <?php |
2 | |||
3 | /** |
||
4 | * Smarty methode Config_Load |
||
5 | * |
||
6 | * Loads a config file |
||
7 | * |
||
8 | * @package Smarty |
||
9 | * @subpackage Config |
||
10 | * @author Uwe Tews |
||
11 | */ |
||
12 | |||
13 | /** |
||
14 | * load a config file optionally load just selected sections |
||
15 | * |
||
16 | * @param object $smarty |
||
17 | * @param string $config_file filename |
||
18 | * @param mixed $sections array of section names, single section or null |
||
19 | */ |
||
20 | function config_load($smarty, $config_file, $sections = null) |
||
21 | { |
||
22 | // load Config class |
||
23 | $smarty->loadPlugin('Smarty_Internal_Config'); |
||
24 | $config = new Smarty_Internal_Config($config_file, $smarty); |
||
25 | $config->loadConfigVars($sections, $smarty); |
||
26 | } |
||
27 | |||
28 | ?> |