NYCPHP Meetup

NYPHP.org

[nycphp-talk] Turning on all warnings, error reporting, collecting debugging info ...

Darryle Steplight dsteplight at gmail.com
Sun Aug 17 18:50:11 EDT 2008


Hi Mike,
  Including ini_set (display_errors,1) might help you out too.
Handling your errors can get pretty deep, but you can implement come
try/catch code around specific sections of your code and then throw
Exceptions with a custom error message of your choice. By default the
error messages will appear in your apache error log. Or you can use
php's error_log() to make the errors appear in your own error log
file.

Check out php's set_error_handler()
too.http://us2.php.net/manual/en/function.set-error-handler.php

On Sun, Aug 17, 2008 at 4:55 PM, Michael B Allen <ioplex at gmail.com> wrote:
> Currently I'm using the following:
>
>  error_reporting(E_ALL|E_STRICT);
>
> at the top of my bootstrap.
>
> Is there anything else I can do to increase warnings and error reporting?
> I use vim+Linux and stock PHP packages. Is there something that
> everyone uses or should use on the server side when writing PHP?
>
> I think I had xdebug enabled on my old machine but I did not notice
> much of a difference aside from the appearance of stack traces.
>
> Mike
> _______________________________________________
> New York PHP Community Talk Mailing List
> http://lists.nyphp.org/mailman/listinfo/talk
>
> NYPHPCon 2006 Presentations Online
> http://www.nyphpcon.com
>
> Show Your Participation in New York PHP
> http://www.nyphp.org/show_participation.php
>



More information about the talk mailing list