aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOleg Pudeyev <oleg@bsdpower.com>2011-05-11 19:38:04 -0400
committerOleg Pudeyev <oleg@bsdpower.com>2011-05-12 20:13:31 -0400
commitd2daaf0317ac6bb224b8f93c1ac9578c9d570dc9 (patch)
tree95606fdb589a6504db9d5e56b3b6900c52b99dff
parent7638bcb56011ebde65005a0ce1abfe7f4a6be4b7 (diff)
downloadforums-d2daaf0317ac6bb224b8f93c1ac9578c9d570dc9.tar
forums-d2daaf0317ac6bb224b8f93c1ac9578c9d570dc9.tar.gz
forums-d2daaf0317ac6bb224b8f93c1ac9578c9d570dc9.tar.bz2
forums-d2daaf0317ac6bb224b8f93c1ac9578c9d570dc9.tar.xz
forums-d2daaf0317ac6bb224b8f93c1ac9578c9d570dc9.zip
[feature/template-engine] Try to handle failed template includes.
PHPBB3-9726
-rw-r--r--phpBB/includes/template.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/phpBB/includes/template.php b/phpBB/includes/template.php
index 2ebbca3568..90b8bb2a22 100644
--- a/phpBB/includes/template.php
+++ b/phpBB/includes/template.php
@@ -508,7 +508,8 @@ class phpbb_template
}
else
{
- // What should we do here?
+ // trigger_error cannot be used here, as the output already started
+ echo 'template->_tpl_include(): Failed including ' . htmlspecialchars($handle) . "\n";
}
}
@@ -525,7 +526,7 @@ class phpbb_template
if (!file_exists($file))
{
// trigger_error cannot be used here, as the output already started
- echo 'template->_php_include(): File ' . htmlspecialchars($file) . ' does not exist or is empty';
+ echo 'template->_php_include(): File ' . htmlspecialchars($file) . " does not exist\n";
return;
}
include($file);