aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Render
diff options
context:
space:
mode:
Diffstat (limited to 'Zotlabs/Render')
-rw-r--r--Zotlabs/Render/Comanche.php19
-rwxr-xr-xZotlabs/Render/SmartyInterface.php2
2 files changed, 13 insertions, 8 deletions
diff --git a/Zotlabs/Render/Comanche.php b/Zotlabs/Render/Comanche.php
index cd06e11a8..fb400b6fe 100644
--- a/Zotlabs/Render/Comanche.php
+++ b/Zotlabs/Render/Comanche.php
@@ -534,7 +534,12 @@ class Comanche {
require_once('widget/' . $clsname . '/' . $clsname . '.php');
elseif(file_exists('Zotlabs/Widget/' . $clsname . '.php'))
require_once('Zotlabs/Widget/' . $clsname . '.php');
-
+ else {
+ $pth = theme_include($clsname . '.php');
+ if($pth) {
+ require_once($pth);
+ }
+ }
if(class_exists($nsname)) {
$x = new $nsname;
$f = 'widget';
@@ -550,11 +555,13 @@ class Comanche {
require_once('widget/' . trim($name) . '.php');
elseif(file_exists('widget/' . trim($name) . '/' . trim($name) . '.php'))
require_once('widget/' . trim($name) . '/' . trim($name) . '.php');
- }
- else {
- $theme_widget = $func . '.php';
- if((! function_exists($func)) && theme_include($theme_widget))
- require_once(theme_include($theme_widget));
+
+ if(! function_exists($func)) {
+ $theme_widget = $func . '.php';
+ if(theme_include($theme_widget)) {
+ require_once(theme_include($theme_widget));
+ }
+ }
}
if(function_exists($func))
diff --git a/Zotlabs/Render/SmartyInterface.php b/Zotlabs/Render/SmartyInterface.php
index 0e3a47c2f..9c9a501c0 100755
--- a/Zotlabs/Render/SmartyInterface.php
+++ b/Zotlabs/Render/SmartyInterface.php
@@ -2,8 +2,6 @@
namespace Zotlabs\Render;
-require_once('library/Smarty/libs/Smarty.class.php');
-
class SmartyInterface extends \Smarty {
public $filename;