I am looking at building my first major application. I've done ton of on the fly projects, but I want to work on designing this one right. I've started usins a abstraction layer for my db, a config file for settings, and smarty for templating. The one thing I'm having a hard time figuring out is error handling.
Most of the tutorials I find for error handling is code that handles a single error like problems with a query, connecting to a db, or file i/o. I am looking for something that I can also use to handle errors for users such as bad data in forms, and things like lack of permissions for a specific feature on the site.
Can anyone suggest if I am trying to shoehorn error handling beyond what I should be? Does anyone know of any good error handling class that will do what I am looking for?
Thanks for the help.