From 734c7c3ebe5a43d47ba112f814c3c3724a114d45 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Wed, 4 Feb 2004 23:14:31 +0000 Subject: [PATCH] Suppression de warnings apparaissant avec register_global=off. --- htdocs/conf/conf.class.php | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/htdocs/conf/conf.class.php b/htdocs/conf/conf.class.php index e29b235dfe3..84d4e974cd6 100644 --- a/htdocs/conf/conf.class.php +++ b/htdocs/conf/conf.class.php @@ -1,6 +1,7 @@ - * Copyright (C) 2003 Xavier Dutoit + * Copyright (C) 2003 Xavier Dutoit + * Copyright (C) 2004 Laurent Destailleur * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -124,13 +125,13 @@ class WebcalConf { $this->enabled = 1; - $this->url = PHPWEBCALENDAR_URL; + $this->url = defined("PHPWEBCALENDAR_URL")?PHPWEBCALENDAR_URL:""; $this->db = new DbConf(); - $this->db->host = PHPWEBCALENDAR_HOST; - $this->db->user = PHPWEBCALENDAR_USER; - $this->db->pass = PHPWEBCALENDAR_PASS; - $this->db->name = PHPWEBCALENDAR_DBNAME; + $this->db->host = defined("PHPWEBCALENDAR_HOST")?PHPWEBCALENDAR_HOST:""; + $this->db->user = defined("PHPWEBCALENDAR_USER")?PHPWEBCALENDAR_USER:""; + $this->db->pass = defined("PHPWEBCALENDAR_PASS")?PHPWEBCALENDAR_PASS:""; + $this->db->name = defined("PHPWEBCALENDAR_DBNAME")?PHPWEBCALENDAR_DBNAME:""; } }