From: "Daevid Vincent" on 11 Jun 2010 19:17 I'm trying to clean up some code and have been looking at error_log output and they all look like this: [11-Jun-2010 23:04:54] <font color='red'><b>In /var/www/my_notifications.php, line 40: WARNING</b> Invalid argument supplied for foreach() </font> I can't figure out: [a] why the logs are in HTML format to begin with? Seems useless. [b] how do I turn it off and just be plain text (i.e. striptags() )? [c] where is this <font color='red'> coming from? I've looked in /etc/php5/apache2/ and grepped through, but don't see 'red' anywhere. I do see this, but it has no effect, as you can see by me 'disabling' it. 388 ; String to output before an error message. 389 ;error_prepend_string = "<font color=ff0000>" 390 error_prepend_string = "" 391 392 ; String to output after an error message. 393 ;error_append_string = "</font>" 394 error_append_string = ""
From: Peter Lind on 12 Jun 2010 05:23 On 12 June 2010 01:17, Daevid Vincent <daevid(a)daevid.com> wrote: > I'm trying to clean up some code and have been looking at error_log output > and they all look like this: > > [11-Jun-2010 23:04:54] <font color='red'><b>In > /var/www/my_notifications.php, line 40: Â WARNING</b> > Invalid argument supplied for foreach() > </font> > > I can't figure out: > > Â Â Â Â [a] why the logs are in HTML format to begin with? Seems useless. > Â Â Â Â [b] how do I turn it off and just be plain text (i.e. striptags() > )? > Â Â Â Â [c] where is this <font color='red'> coming from? > > I've looked in /etc/php5/apache2/ and grepped through, but don't see 'red' > anywhere. > > I do see this, but it has no effect, as you can see by me 'disabling' it. > > Â 388 ; String to output before an error message. > Â 389 ;error_prepend_string = "<font color=ff0000>" > Â 390 error_prepend_string = "" > Â 391 > Â 392 ; String to output after an error message. > Â 393 ;error_append_string = "</font>" > Â 394 error_append_string = "" > Did you check the html_errors directive? Regards Peter -- <hype> WWW: http://plphp.dk / http://plind.dk LinkedIn: http://www.linkedin.com/in/plind BeWelcome/Couchsurfing: Fake51 Twitter: http://twitter.com/kafe15 </hype>
From: Peter Lind on 12 Jun 2010 05:32 On 12 June 2010 11:23, Peter Lind <peter.e.lind(a)gmail.com> wrote: > On 12 June 2010 01:17, Daevid Vincent <daevid(a)daevid.com> wrote: >> I'm trying to clean up some code and have been looking at error_log output >> and they all look like this: >> >> [11-Jun-2010 23:04:54] <font color='red'><b>In >> /var/www/my_notifications.php, line 40: Â WARNING</b> >> Invalid argument supplied for foreach() >> </font> >> >> I can't figure out: >> >> Â Â Â Â [a] why the logs are in HTML format to begin with? Seems useless. >> Â Â Â Â [b] how do I turn it off and just be plain text (i.e. striptags() >> )? >> Â Â Â Â [c] where is this <font color='red'> coming from? >> >> I've looked in /etc/php5/apache2/ and grepped through, but don't see 'red' >> anywhere. >> >> I do see this, but it has no effect, as you can see by me 'disabling' it.. >> >> Â 388 ; String to output before an error message. >> Â 389 ;error_prepend_string = "<font color=ff0000>" >> Â 390 error_prepend_string = "" >> Â 391 >> Â 392 ; String to output after an error message. >> Â 393 ;error_append_string = "</font>" >> Â 394 error_append_string = "" >> > > Did you check the html_errors directive? Other thing that comes to mind is xdebug which will format error output - not sure if that ends up in the error log though. Regards Peter -- <hype> WWW: http://plphp.dk / http://plind.dk LinkedIn: http://www.linkedin.com/in/plind BeWelcome/Couchsurfing: Fake51 Twitter: http://twitter.com/kafe15 </hype>
|
Pages: 1 Prev: Using LDAPS with PHP / certificates Next: How to change the first line of a text file |