diff --git a/library/smarty/libs/sysplugins/smarty_internal_compile_config_load.php b/library/smarty/libs/sysplugins/smarty_internal_compile_config_load.php new file mode 100644 --- /dev/null +++ b/library/smarty/libs/sysplugins/smarty_internal_compile_config_load.php @@ -0,0 +1,79 @@ + true, 'parent' => true, 'root' => true, 'global' => true); + // check and get attributes + $_attr = $this->getAttributes($compiler, $args); + + if ($_attr['nocache'] === true) { + $compiler->trigger_template_error('nocache option not allowed', $compiler->lex->taglineno); + } + + // save possible attributes + $conf_file = $_attr['file']; + if (isset($_attr['section'])) { + $section = $_attr['section']; + } else { + $section = 'null'; + } + $scope = 'local'; + // scope setup + if (isset($_attr['scope'])) { + $_attr['scope'] = trim($_attr['scope'], "'\""); + if (isset($_is_legal_scope[$_attr['scope']])) { + $scope = $_attr['scope']; + } else { + $compiler->trigger_template_error('illegal value for "scope" attribute', $compiler->lex->taglineno); + } + } + // create config object + $_output = ""; + + return $_output; + } +}