Вопрос

I have automated my error_reporting process. Errors are logged to a file and periodically sent via email.

Problem is I don't get enough information. E.g. I can see a undefined index notice; but I can't see where it was triggered as often its an included file.

Is it possible to get a dump of $_SERVER in the error log?

Это было полезно?

Решение

What I would do is to catch errors using this then log my custom error using this

Другие советы

You can use function debug_backtrace

Function return backtrace for current position.

For Include $_SERVER to email you can use print_r($_SERVER, true); but I think this can help you little.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top