From 4bf41b8e5db7c933f1b8cd3738c32a375866d4b5 Mon Sep 17 00:00:00 2001 From: Fabrixxm Date: Wed, 8 May 2013 03:26:20 -0400 Subject: [PATCH 1/2] check if view/smarty3 folder is writable by webserver --- include/friendica_smarty.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/include/friendica_smarty.php b/include/friendica_smarty.php index 1326b0aca6..021feea2ac 100644 --- a/include/friendica_smarty.php +++ b/include/friendica_smarty.php @@ -45,6 +45,13 @@ class FriendicaSmarty extends Smarty { class FriendicaSmartyEngine implements ITemplateEngine { static $name ="smarty3"; + + public function __construct(){ + if(!is_writable('view/smarty3/')){ + echo "ERROR: folder view/tpl/smarty3/ must be writable by webserver."; killme(); + } + } + // ITemplateEngine interface public function replace_macros($s, $r) { $template = ''; From 2da4f8268e74240212c557d3458a744f997c2eff Mon Sep 17 00:00:00 2001 From: fabrixxm Date: Wed, 8 May 2013 11:34:30 +0300 Subject: [PATCH 2/2] fix smarty3 folder not writable message --- include/friendica_smarty.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/friendica_smarty.php b/include/friendica_smarty.php index 021feea2ac..b516926754 100644 --- a/include/friendica_smarty.php +++ b/include/friendica_smarty.php @@ -48,7 +48,7 @@ class FriendicaSmartyEngine implements ITemplateEngine { public function __construct(){ if(!is_writable('view/smarty3/')){ - echo "ERROR: folder view/tpl/smarty3/ must be writable by webserver."; killme(); + echo "ERROR: folder view/smarty3/ must be writable by webserver."; killme(); } }