diff options
author | Andreas Gohr <andi@splitbrain.org> | 2014-02-02 20:37:56 +0100 |
---|---|---|
committer | Andreas Gohr <andi@splitbrain.org> | 2014-02-02 20:37:56 +0100 |
commit | 9585623da6462d613fea9809128d1153adfe573d (patch) | |
tree | 0202e550476b28face49443ecad73bd76019db8f | |
parent | 0453b6136126926f4e15e2d7a366450336968c78 (diff) | |
parent | 17448fb8ad4bfc5bbabcbd5419cafdef1b9be18f (diff) | |
download | rpg-9585623da6462d613fea9809128d1153adfe573d.tar.gz rpg-9585623da6462d613fea9809128d1153adfe573d.tar.bz2 |
Merge remote-tracking branch 'origin/PR523'
* origin/PR523:
Update tpl_getConf() signature to match plugin::getConf()
-rw-r--r-- | inc/template.php | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/inc/template.php b/inc/template.php index 60e178d1a..0a6a9e4aa 100644 --- a/inc/template.php +++ b/inc/template.php @@ -1123,10 +1123,11 @@ function tpl_indexerWebBug() { * * use this function to access template configuration variables * - * @param string $id - * @return string + * @param string $id name of the value to access + * @param mixed $notset what to return if the setting is not available + * @return mixed */ -function tpl_getConf($id) { +function tpl_getConf($id, $notset=false) { global $conf; static $tpl_configloaded = false; @@ -1143,7 +1144,11 @@ function tpl_getConf($id) { } } - return $conf['tpl'][$tpl][$id]; + if(isset($conf['tpl'][$tpl][$id])){ + return $conf['tpl'][$tpl][$id]; + } + + return $notset; } /** |