HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   Server Operation (http://www.howtoforge.com/forums/forumdisplay.php?f=5)
-   -   apache and php error logs in same dir as faulting script? (http://www.howtoforge.com/forums/showthread.php?t=50980)

talkingnews 17th January 2011 14:45

apache and php error logs in same dir as faulting script?
 
Finally, after much searching, I found a way to make php write the error log file to the same directory as the troublesome script.
The answer is
Quote:

In the start of the scripts where you want to capture the error data, use ini_set('error_log', getcwd().'/errorfile.log');. This will set the error logging temporarily to the directory that your script is working in.
Now, as Professor Frink might say, it should be obvious to even the most dimwitted individual that this is an excellent thing, and something I greatly missed when moving away from cpanel and have been looking for ever since.

The problem is, the rest of that thread is people wondering the same as me without any result is - how can I get the server to somehow do this for ALL php files, without having to append this to every script? The answer, as others have found, doesn't appear to lie with adding it to php.ini.
Unless I'm doing it wrong?

Incidentally, I'm on ISPCONFIG 3.03


All times are GMT +2. The time now is 15:50.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.