Frage

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?

War es hilfreich?

Lösung

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

Andere Tipps

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.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top