A message about the exception using XDebug [PHP]

Warning: count(): Parameter must be an array or an object that implements Countable in /home/styllloz/public_html/qa-theme/donut-theme/qa-donut-layer.php on line 274
0 like 0 dislike
Display error messages and exceptions using xdebug quite comfortable.
But besides the output is the task to caloghirou encountered an error and send a mail to the administrator.

Put your handler using set_error_handler and set_exception_handler.
The processors perform all necessary actions, in set_error_handler then do return false and start the xdebug error handler that displays a message on the screen, and for the exception handler there is no such mechanism to call the previous handler is impossible.

Has anyone faced such a problem?
by | 5 views

2 Answers

0 like 0 dislike
It seems to me to send an error message by email from php is wrong.
It is more logical once an hour great error_log and send it in the mail.
0 like 0 dislike
Ahem... or I not understand you correctly... or...
When you call set_exception_handler() sort returns the name of the previous handler, which nobody bothers to save and later recall.

Related questions

0 like 0 dislike
3 answers
asked Jun 3, 2019 by vadimpopov94
0 like 0 dislike
1 answer
asked Mar 24, 2019 by DexterHD
0 like 0 dislike
2 answers
asked Mar 25, 2019 by iandriyanov
110,608 questions
257,186 answers
28,009 users