X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=include%2Fphp_setup.inc;h=e83379c9826cdd039a758e2d177d6658e75e8a22;hb=2255bc8f95b2e1159d9306a99f1c563536eb06c6;hp=5fcfd69d0689d6628d27cd9d06c0b0dfa7dcd0d6;hpb=d2726983b0ac889de817ab5162cfbc7204a6e4fd;p=gosa.git
diff --git a/include/php_setup.inc b/include/php_setup.inc
index 5fcfd69d0..e83379c98 100644
--- a/include/php_setup.inc
+++ b/include/php_setup.inc
@@ -54,7 +54,8 @@ function gosaRaiseError($errno, $errstr, $errfile, $errline)
}
if((isset($config->data))){
- if((isset($config->data['MAIN']['DISPLAYERRORS']))&&(!preg_match("/true/i",$config->data['MAIN']['DISPLAYERRORS']))){
+ if((isset($config->data['MAIN']['DISPLAYERRORS']))&&(!preg_match("/^true$/i",$config->data['MAIN']['DISPLAYERRORS']))){
+
/* Write to syslog */
gosa_log ("PHP error: $errstr ($errfile, line $errline)");
return;
@@ -64,10 +65,10 @@ function gosaRaiseError($errno, $errstr, $errfile, $errline)
/* Create header as needed */
if ($error_collector == ""){
- if ($_SESSION['js']==FALSE){
+ if (isset($_SESSION['js']) && $_SESSION['js']==FALSE){
$error_collector= "
";
} else {
- $error_collector= "
"._("Generating this page caused the PHP interpreter to raise some errors!")." | |
";
+ $error_collector= "
"._("Generating this page caused the PHP interpreter to raise some errors!")." | |
";
}
}
@@ -79,7 +80,7 @@ function gosaRaiseError($errno, $errstr, $errfile, $errline)
$trace= debug_backtrace();
/* Generate trace history */
- for ($index= 1; $index"._("Trace")."[$index]: $loc | ";
$error_collector.= ""._("File").": $file ("._('Line')." $line) | "._("Type").": $type | ";
@@ -163,5 +178,10 @@ $smarty->template_dir = $BASE_DIR.'/ihtml/';
$smarty->caching= false;
$smarty->php_handling= SMARTY_PHP_REMOVE;
+/* Set timezone */
+if (function_exists("date_default_timezone_set")){
+ date_default_timezone_set("GMT");
+}
+
// vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
?>