From: cajus Date: Wed, 18 May 2005 19:13:56 +0000 (+0000) Subject: Added error handling for login and themes X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=be51930cd79f80d0bd75c1156c66c1c396a7b1d5;p=gosa.git Added error handling for login and themes git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@251 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/html/index.php b/html/index.php index 9ced14d67..d218040f2 100644 --- a/html/index.php +++ b/html/index.php @@ -23,6 +23,10 @@ require_once ("../include/php_setup.inc"); require_once ("functions.inc"); header("Content-type: text/html; charset=UTF-8"); +/* Reset error handler */ +$error_collector= ""; +set_error_handler('gosaRaiseError'); + /* Set error handler to own one, initialize time calculation and start session. */ session_start (); @@ -232,6 +236,7 @@ $smarty->assign ("PHPSESSID", session_id()); if (isset($_SESSION['errors'])){ $smarty->assign("errors", $_SESSION['errors']); } +$smarty->assign("php_error", $error_collector); $smarty->display (get_template_path('login.tpl')); // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler: diff --git a/ihtml/themes/altlinux/framework.tpl b/ihtml/themes/altlinux/framework.tpl index c40913bf8..fea2a6785 100644 --- a/ihtml/themes/altlinux/framework.tpl +++ b/ihtml/themes/altlinux/framework.tpl @@ -1,5 +1,6 @@ +{$php_errors}
diff --git a/ihtml/themes/altlinux/login.tpl b/ihtml/themes/altlinux/login.tpl index 05df7a9d8..726922eed 100644 --- a/ihtml/themes/altlinux/login.tpl +++ b/ihtml/themes/altlinux/login.tpl @@ -2,6 +2,7 @@ {$errors} +{$php_errors}
diff --git a/ihtml/themes/classic/framework.tpl b/ihtml/themes/classic/framework.tpl index bea694193..919040963 100644 --- a/ihtml/themes/classic/framework.tpl +++ b/ihtml/themes/classic/framework.tpl @@ -1,4 +1,5 @@ +{$php_errors}