Page 1 of 1

[SOLVED]Is it possible to store ERRORs into the Database?

Posted: Fri Sep 24, 2004 3:42 am
by myleow
I am dealing with a foreign device and wish to know what PHP Errors were generated.

Is there a way to store the Error generated into the Database?

I know you can just log any logical errors but how do you deal with syntatical errors (whatever it is called)

Regards
Mian

P.S. Doesn't necessary have to be Error, can be Warning too. As long as it is something that will pop up on a Browser that is not suppose to.

Posted: Fri Sep 24, 2004 4:14 am
by patrikG
[php_man]ob_start[/php_man] is one of PHP's output buffering functions. Grab the buffered content and insert it into the DB.

Posted: Fri Sep 24, 2004 6:50 am
by feyd
you could set your own function as the error processor.. [php_man]set_error_handler[/php_man]

Posted: Fri Sep 24, 2004 2:43 pm
by myleow
Thanks