Managing errors

Not for 'how-to' coding questions but PHP theory instead, this forum is here for those of us who wish to learn about design aspects of programming with PHP.

Moderator: General Moderators

Post Reply
timbrown
Forum Newbie
Posts: 14
Joined: Wed Feb 21, 2007 7:48 am

Managing errors

Post by timbrown »

Hi,

I am building an application and want a way to manage the errors that it produces. Something like when you get error number 1234 etc.

I am not referring to actual PHP generated errors, I mean notices that my application generates for example when someone tries to do something I dont like OR a function returns unexpected results.

Is there an accepted method of doing this when building applications?
User avatar
Jenk
DevNet Master
Posts: 3587
Joined: Mon Sep 19, 2005 6:24 am
Location: London

Post by Jenk »

For php5 you can utilise exceptions, and create an exception handler.

Exceptions are pretty much standard behaviour amongst multiple languages.
timbrown
Forum Newbie
Posts: 14
Joined: Wed Feb 21, 2007 7:48 am

Post by timbrown »

Jenk wrote:For php5 you can utilise exceptions, and create an exception handler.

Exceptions are pretty much standard behaviour amongst multiple languages.
That's just what Im after. Thanks. :)
Post Reply