summaryrefslogtreecommitdiff
path: root/inc/template.php
diff options
context:
space:
mode:
authorAnika Henke <anika@selfthinker.org>2010-11-12 20:34:00 +0100
committerAnika Henke <anika@selfthinker.org>2010-11-12 20:34:00 +0100
commitafca7e7eb41bc692ca11c4fb80f32c860e2bd3d5 (patch)
tree70c1e60246ebb5c0b3954d4f04e0c238395a8130 /inc/template.php
parentb190e58905738aad7360936a92ffdabbca95d160 (diff)
downloadrpg-afca7e7eb41bc692ca11c4fb80f32c860e2bd3d5.tar.gz
rpg-afca7e7eb41bc692ca11c4fb80f32c860e2bd3d5.tar.bz2
FS#1839: take favicon from mediadir (if it exists)
Diffstat (limited to 'inc/template.php')
-rw-r--r--inc/template.php13
1 files changed, 13 insertions, 0 deletions
diff --git a/inc/template.php b/inc/template.php
index cb98c83d7..00bfde723 100644
--- a/inc/template.php
+++ b/inc/template.php
@@ -1359,5 +1359,18 @@ function tpl_flush(){
}
+/**
+ * Use favicon.ico from data/media root directory if it exists, otherwise use
+ * the one in the template's image directory.
+ *
+ * @author Anika Henke <anika@selfthinker.org>
+ */
+function tpl_getFavicon() {
+ if (file_exists(mediaFN('favicon.ico')))
+ return ml('favicon.ico');
+ return DOKU_TPL.'images/favicon.ico';
+}
+
+
//Setup VIM: ex: et ts=4 enc=utf-8 :