Page 1 of 1

APC: Logging for compile errors?

Posted: Fri Jun 12, 2009 3:04 pm
by joshw
I've been happily using APC for the last few months, but there's one problem I've been having. It seems that since APC is in charge of compiling the code, it's also in charge of logging compile errors. Except that... well, it doesn't. My error_log only contains runtime errors. Parse errors only come through when I disable APC.

How can I log compile errors when using APC?

Re: APC: Logging for compile errors?

Posted: Fri Jun 12, 2009 3:30 pm
by Mark Baker
Test every script by doing

Code: Select all

php -l filename.php
from the command line

You can also use apc_compile_file() to compile the file from within a script. This function returns false if there are errors