From 6691618d2b2b8c93790938e80ae94c503610950f Mon Sep 17 00:00:00 2001 From: Indieteq Date: Mon, 12 Nov 2012 14:02:42 +0100 Subject: Update Log.class.php --- Log.class.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Log.class.php b/Log.class.php index ec291cb..07ccd04 100644 --- a/Log.class.php +++ b/Log.class.php @@ -35,7 +35,7 @@ if(is_dir($this->path)) { if(!file_exists($log)) { - $fh = fopen($log, 'w') or die("Fatal Error !"); + $fh = fopen($log, 'a+') or die("Fatal Error !"); $logcontent = "Time : " . $date->format('H:i:s')."\r\n" . $message ."\r\n"; fwrite($fh, $logcontent); fclose($fh); @@ -45,7 +45,7 @@ } } else { - if(mkdir($this->path,0777) === true) // Check on true, Otherwise we would have a never-ending loop :S + if(mkdir($this->path,0777) === true) { $this->write($message); } -- cgit v1.1