Skip to content

Commit e35b05b

Browse files
committed
closes #5
1 parent 85af8b6 commit e35b05b

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

code/Fields.class.php

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
use FormTools\Modules;
1010
use FormTools\Sessions;
1111
use PDO, PDOException;
12-
use Smarty;
12+
use Smarty, SmartyBC;
1313

1414

1515

@@ -390,7 +390,12 @@ public static function displayFields($location, $template_vars)
390390
return "";
391391
}
392392

393-
$smarty = new Smarty();
393+
if (method_exists(new Core(), "useSmartyBC")) {
394+
$smarty = Core::useSmartyBC() ? new SmartyBC() : new Smarty();
395+
} else {
396+
$smarty = new Smarty();
397+
}
398+
394399
$smarty->setCompileDir("$root_dir/themes/default/cache/");
395400
$smarty->addPluginsDir(array(
396401
"$root_dir/global/smarty_plugins",

0 commit comments

Comments
 (0)