From 31a21ac24cd5cbe19e40ab3838fcc179d812da13 Mon Sep 17 00:00:00 2001 From: fabrixxm Date: Wed, 8 May 2013 03:51:38 -0400 Subject: use smarty3 as default template engine. add pluggable template system --- include/plugin.php | 21 +++------------------ 1 file changed, 3 insertions(+), 18 deletions(-) mode change 100644 => 100755 include/plugin.php (limited to 'include/plugin.php') diff --git a/include/plugin.php b/include/plugin.php old mode 100644 new mode 100755 index 31427e117..3ef97fba9 --- a/include/plugin.php +++ b/include/plugin.php @@ -569,24 +569,9 @@ function get_intltext_template($s) { function get_markup_template($s, $root = '') { - $a = get_app(); - - $template_eng = $a->get_template_engine(); - if($template_eng === 'internal') { - $template_file = theme_include($s, $root); - if($template_file) - return file_get_contents($template_file); - } - else { - $template_file = theme_include("$template_eng/$s", $root); - - if($template_file) { - $template = new FriendicaSmarty(); - $template->filename = $template_file; - - return $template; - } - } + $t = $a->template_engine(); + $template = $t->get_markup_template($s, $root); + return $template; } -- cgit v1.2.3