diff options
author | Anika Henke <anika@selfthinker.org> | 2013-08-03 14:19:12 -0700 |
---|---|---|
committer | Anika Henke <anika@selfthinker.org> | 2013-08-03 14:19:12 -0700 |
commit | acdd81e3745ce18e31823d16d530d0b5b287ca09 (patch) | |
tree | 51bda97ffa294dc5d945e17bf11a9037ef482873 /inc/template.php | |
parent | da616cb12d66e3f56b9d0d2a93705cf43c1eab00 (diff) | |
parent | 2d59ebc34b9c4c4b7b70096f9dbd1621eb13883f (diff) | |
download | rpg-acdd81e3745ce18e31823d16d530d0b5b287ca09.tar.gz rpg-acdd81e3745ce18e31823d16d530d0b5b287ca09.tar.bz2 |
Merge pull request #262 from splitbrain/confstyleini
allow for a style.ini in conf/<tpl>/style.ini
Diffstat (limited to 'inc/template.php')
-rw-r--r-- | inc/template.php | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/inc/template.php b/inc/template.php index ca1c8d9d5..f6eb488f5 100644 --- a/inc/template.php +++ b/inc/template.php @@ -33,11 +33,13 @@ function template($file) { * This replaces the deprecated DOKU_TPLINC constant * * @author Andreas Gohr <andi@splitbrain.org> + * @param string $tpl The template to use, default to current one * @return string */ -function tpl_incdir() { +function tpl_incdir($tpl='') { global $conf; - return DOKU_INC.'lib/tpl/'.$conf['template'].'/'; + if(!$tpl) $tpl = $conf['template']; + return DOKU_INC.'lib/tpl/'.$tpl.'/'; } /** @@ -46,10 +48,12 @@ function tpl_incdir() { * This replaces the deprecated DOKU_TPL constant * * @author Andreas Gohr <andi@splitbrain.org> + * @param string $tpl The template to use, default to current one * @return string */ -function tpl_basedir() { +function tpl_basedir($tpl) { global $conf; + if(!$tpl) $tpl = $conf['template']; return DOKU_BASE.'lib/tpl/'.$conf['template'].'/'; } |