Error Handling In PHP (part 2) - Endgame (
Page 8 of 8 )
And that's about it from me. In
this two-part article, you learned how to use PHP's error-handling API to exert
fine-grained control over the way the language handles errors. You learned how
to control the display of specific error types, how to customize the manner in
which they're handled, and how to raise errors of your own. Next, you learnt how
to log errors, write them to a file and email them out to all and sundry. And,
as if all that wasn't enough, the final section of this article demonstrated the
process of creating a robust, scalable error-handling system for a Web
application.
In case you'd like to know more about the material discussed
in this article, consider checking out the following links:
A
description of PHP error types, at
http://www.php.net/manual/en/phpdevel-errors.phpGyozo
Papp's ErrorHandler class, at
http://www.phpclasses.org/browse.html/package/345PHP
output buffering, at
http://www.php.net/manual/en/ref.outcontrol.phpPHP's
MySQL functions, at
http://www.php.net/manual/en/ref.mysql.phpPHP's
file handling functions, at
http://www.php.net/manual/en/ref.filesystem.phpI
hope you enjoyed this article, and that you found it interesting and
informative. Till next time...be good!
Note: All examples in this article
have been tested on Linux/i586 with Apache 1.3.20 and PHP 4.1.1. Examples are
illustrative only, and are not meant for a production environment. Melonfire
provides no warranties or support for the source code described in this article.
YMMV!