Login   Register  
PHP Classes
elePHPant
Icontem

Handling Notice and Warning as Exception: Throw exceptions when PHP warnings are triggered

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Info   View files View files (2)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings  
2011-06-10 (3 years ago) RSS 2.0 feedNot enough user ratingsTotal: 897 This week: 1All time: 3,669 This week: 1,384Up
Version License PHP version Categories  
nwexceptions 0.1GNU Lesser General Publ...5.0PHP 5, Debug, Language
Description Author  

This package can throw exceptions when PHP warnings are triggered.

It registers a PHP error handler that throws special exception classes when a PHP warning or notice is triggered.

The exception messages display the file name and line of the PHP code where the warnings or notices were triggered.

Innovation Award  
PHP Programming Innovation award nominee
June 2011
Number 2
In PHP, when a non-fatal error occurs, PHP issues a notice or a warning but continues to execute the code regularly as if nothing happened, so certain problems may occur due to unhandled errors.

This class implements a solution that allows you to prevent that those problems happen by throwing an exception when a notice or a warning is issued.

Manuel Lemos
Picture of Andrey Nikishaev
Name: Andrey Nikishaev is available for providing paid consulting. Contact Andrey Nikishaev .
Classes: 13 packages by
Country: Ukraine Ukraine
Age: 28
All time rank: 2456 in Ukraine Ukraine
Week rank: 312 Down8 in Ukraine Ukraine Down
Innovation award
Innovation award
Nominee: 2x

Winner: 1x

  Files folder image Files  
File Role Description
Plain text file nwexceptions.php Class main file
Accessible without login Plain text file example.php Example Example of use

 Version Control Unique User Downloads Download Rankings  
 0%Total:897All time:3,669
 This week:1This week:1,384Up