Ready to use Error handling class in your hosted php application
Hello Friends,
I have wriiten a class for error reporitng in a php web application. It is a ready made one..
you have to provide your email id.
If you work in localhost it will provide you error in the same page as it occur
but in hosted application the client will only get a custom error message. The same time our error handler class will send a mail to your email id as it occure..
Configuration on error.class.php
/**
* Configuration variables.
* @param email
* @param time zone
* $param application name
*/
$email = ‘arunet@gmail.com’;
date_default_timezone_set(“UTC”);
$app_name = ‘Name of the application’;
save this file with extension .php
How to use it ?
Just include this line in each php page
<?php include_once(“error.class.php”) ;?>
Eg.
<?php
include_once(“error.class.php”);
$xmlstr = file_get_contents(‘library.xml’);
?>