summaryrefslogtreecommitdiffstats
path: root/lib/kolab_client_output.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/kolab_client_output.php')
-rw-r--r--lib/kolab_client_output.php15
1 files changed, 14 insertions, 1 deletions
diff --git a/lib/kolab_client_output.php b/lib/kolab_client_output.php
index 6454acf..d40c323 100644
--- a/lib/kolab_client_output.php
+++ b/lib/kolab_client_output.php
@@ -51,7 +51,20 @@ class kolab_client_output
*/
private function init()
{
- require_once 'Smarty/Smarty.class.php';
+ $conf = Conf::get_instance();
+
+ $smarty_path = array('Smarty', 'smarty3', 'smarty');
+
+ if ($path = $conf->get('kolab_wap', 'smarty_path')) {
+ array_unshift($smarty_path, $path);
+ }
+
+ foreach ($smarty_path as $path) {
+ @include_once "$path/Smarty.class.php";
+ if (class_exists('Smarty', false)) {
+ break;
+ }
+ }
$SMARTY = new Smarty;