]> git.mxchange.org Git - friendica.git/blobdiff - boot.php
Merge pull request #552 from annando/master
[friendica.git] / boot.php
index 48330212d9b282d5299a0ec48d84b870c8a8026b..d8bc174b4a25c8bb64ff85713d02e3f8367eda63 100644 (file)
--- a/boot.php
+++ b/boot.php
@@ -1946,3 +1946,18 @@ function clear_cache($basepath = "", $path = "") {
                closedir($dh);
        }
 }
+
+function set_template_engine(&$a, $engine = 'internal') {
+
+       $a->theme['template_engine'] = 'internal';
+
+       if(is_writable('view/smarty3/')) {
+               switch($engine) {
+                       case 'smarty3':
+                               $a->theme['template_engine'] = 'smarty3';
+                               break;
+                       default:
+                               break;
+               }
+       }
+}