Commit eef47c12 authored by Ad Schellevis's avatar Ad Schellevis Committed by Franco Fichtner

(legacy) fix some more php notices

parent be6406d0
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
/* Include authentication routines */ /* Include authentication routines */
/* THIS MUST BE ABOVE ALL OTHER CODE */ /* THIS MUST BE ABOVE ALL OTHER CODE */
if(!$nocsrf) { if(isset($nocsrf) && !$nocsrf) {
function csrf_startup() { function csrf_startup() {
csrf_conf('rewrite-js', '/csrf/csrf-magic.js'); csrf_conf('rewrite-js', '/csrf/csrf-magic.js');
...@@ -42,7 +42,7 @@ function csrf_startup() { ...@@ -42,7 +42,7 @@ function csrf_startup() {
} }
/* make sure nothing is cached */ /* make sure nothing is cached */
if (!$omit_nocacheheaders) { if (isset($omit_nocacheheaders) && $omit_nocacheheaders) {
header("Expires: 0"); header("Expires: 0");
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
header("Cache-Control: no-store, no-cache, must-revalidate"); header("Cache-Control: no-store, no-cache, must-revalidate");
...@@ -58,9 +58,9 @@ require_once("functions.inc"); ...@@ -58,9 +58,9 @@ require_once("functions.inc");
$g['theme'] = get_current_theme(); $g['theme'] = get_current_theme();
/* Set the default interface language */ /* Set the default interface language */
if($config['system']['language'] <> "") { if(isset($config['system']['language']) && $config['system']['language'] <> "") {
$g['language'] = $config['system']['language']; $g['language'] = $config['system']['language'];
} elseif ($g['language'] == "") { } elseif (!isset($g['language']) || $g['language'] == "") {
$g['language'] = 'en_US'; $g['language'] = 'en_US';
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment