Is possible to create logs in another file and folder? - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28) +--- Forum: CodeIgniter 4 Support (https://forum.codeigniter.com/forumdisplay.php?fid=30) +--- Thread: Is possible to create logs in another file and folder? (/showthread.php?tid=78665) |
Is possible to create logs in another file and folder? - AngelRodriguez - 02-22-2021 Hi, I want to create logs in different folders with different names. Is it possible? (I'm using CI4 system Logger) For example: /logs /app applog-date.log applog-date.log /other otherlog-date.log otherlog-date.log Thank you RE: Is possible to create logs in another file and folder? - paliz - 02-22-2021 (02-22-2021, 11:42 AM)AngelRodriguez Wrote: Hi, ci4 already had intergrate logger in write folder see there RE: Is possible to create logs in another file and folder? - kenjis - 02-22-2021 It seems it is possible if you create another Logger instance for another log path by yourself. RE: Is possible to create logs in another file and folder? - AngelRodriguez - 02-23-2021 (02-22-2021, 04:40 PM)kenjis Wrote: It seems it is possible if you create another Logger instance for another log path by yourself. Im using 4.0.4 and is not possible in this version change the path. I need to update to 4.1.1 and it works thank you RE: Is possible to create logs in another file and folder? - motownphilippe - 03-04-2021 Could you please describe exactly how you achieved this. I am trying to group messages of a similar kind into a separate file. I can’t work out how to change log path at run time. RE: Is possible to create logs in another file and folder? - AngelRodriguez - 03-04-2021 (03-04-2021, 06:05 AM)motownphilippe Wrote: Could you please describe exactly how you achieved this. PHP Code: use Config\Logger as LoggerConfig; |