CodeIgniter Forums
how can i put all eror in same log file - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21)
+--- Thread: how can i put all eror in same log file (/showthread.php?tid=9587)



how can i put all eror in same log file - El Forum - 06-30-2008

[eluser]Zeeshan Rasool[/eluser]
Hi, guys there is a little prob. Here , i have a code that generates error log file

Code:
$dbRet=$this->db->insert('hfelp_video');
             if (!$dbRet) {
             $errNo   = $this->db->_error_number();
                $errMess = $this->db->_error_message();

            log_message("error", "Problem Inserting to".$errMess." (".$errNo.")");

but, it generates new file daily with current date file name i-e

log-2008-06-30.php , log-2008-07-01.php etc

how can i put all eror in same log file

thnx in adv.


how can i put all eror in same log file - El Forum - 07-01-2008

[eluser]Zeeshan Rasool[/eluser]
change log.php

Code:
$filepath = $this->log_path.'log-'.Date(Y'M'D,).EXT;  to
    
$filepath = $this->log_path.'Errorlog'.EXT;