Hello, how I can pass \r\n in error_log ? it always stripped and my custom error log is one line long ;-(
Unfortunetly this project is on windozze with Apache.
Not sure if this is exactly what you're looking for, but it may help:
When outputting to syslog, it uses the syslog() function, which limits its output to 500 characters. We have been able to send multi-line output to the log, but newlines appear to be replaced with a space in the output, and output is cut off at 500 characters. A simple workaround for long, multi-line output is something like this: $errlines = explode("\n",$errmsg); foreach ($errlines as $txt) { error_log($txt); }
When outputting to syslog, it uses the syslog() function, which limits its output to 500 characters. We have been able to send multi-line output to the log, but newlines appear to be replaced with a space in the output, and output is cut off at 500 characters.
A simple workaround for long, multi-line output is something like this:
$errlines = explode("\n",$errmsg); foreach ($errlines as $txt) { error_log($txt); }
Found it here