-
Notifications
You must be signed in to change notification settings - Fork 0
ErrorHandling
This documentation will help you to better understand how errors are handled within the CoreyPHP library.
- Error Handling Strategy
- Public Error Management Methods
- Internal Error Dispatching
- Custom Error Views
The CoreyPHP library uses an adaptive, environment-aware error reporting pipeline. Depending on your configuaration settings and PHP ini environment values, the library intelligently chooses between throwing exceptions, triggering native user-level errors, or safely formatting debugging dumps.
These are the public-facing methods you can use to explicitly route caught errors or pass system logs through the CoreyPHP formatting engines.
When an unexpected exception slips past your custom app logic and is processed directly by exceptionMsg(), CoreyPHP outputs a clean developer block containing critical data points:
- Error Title: Labeled prominently as CoreyPHP Exception.
- File metadata: Explicit line references tracking the origin.
- Stack Trace: A boxed preformatted trace dump highlighting execution steps.
NOTE: In production environments, ensure
debugis turned off anddisplay_errorsis set to0in your php.ini settings to prevent leaking these detailed code views to users.
Home | Error Handling