Files
smarty/libs/sysplugins/method.get_config_vars.php
Uwe.Tews d2d8c8925b - removed all internal calls of Smarty::instance()
- fixed code in double quoted strings
2009-08-08 17:28:23 +00:00

37 lines
689 B
PHP

<?php
/**
* Smarty method Get_Config_Vars
*
* Returns a single or all global config variables
*
* @package Smarty
* @subpackage SmartyMethod
* @author Uwe Tews
*/
/**
* Returns a single or all global config variables
*/
/**
* Returns a single or all global config variables
*
* @param string $varname variable name or null
* @return string variable value or or array of variables
*/
function Get_Config_Vars($smarty, $varname = null)
{
if (isset($varname)) {
if (isset($smarty->config_vars[$varname])) {
return $smarty->config_vars[$varname];
} else {
return '';
}
} else {
return $smarty->config_vars;
}
}
?>