|
From: Benjamin C. <bc...@us...> - 2002-04-08 17:05:53
|
Update of /cvsroot/phpbt/phpbt
In directory usw-pr-cvs1:/tmp/cvs-serv28684
Modified Files:
include.php
Log Message:
Show a nice error message if smarty is not available
Index: include.php
===================================================================
RCS file: /cvsroot/phpbt/phpbt/include.php,v
retrieving revision 1.109
retrieving revision 1.110
diff -u -r1.109 -r1.110
--- include.php 8 Apr 2002 15:19:33 -0000 1.109
+++ include.php 8 Apr 2002 17:04:12 -0000 1.110
@@ -95,9 +95,13 @@
$default_db_fields = array('bug_id', 'title', 'reporter', 'owner',
'severity_name', 'priority', 'status_name', 'resolution_name');
-require(SMARTY_PATH . 'Smarty.class.php'); // Template class
// Template class
+if (!@include(SMARTY_PATH . 'Smarty.class.php')) {
+ include('templates/default/base/smartymissing.html');
+ exit;
+}
+
class extSmarty extends Smarty {
function fetch($_smarty_tpl_file, $_smarty_cache_id = null, $_smarty_compile_id = null, $_smarty_display = false) {
|