Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set of features to safely use PHP-Error on production environment #62

Open
wants to merge 27 commits into
base: master
Choose a base branch
from

Conversation

panrafal
Copy link

@panrafal panrafal commented Feb 3, 2013

This is just a merge of all my features from the other pull requests with necessary small fixes to make them work together in concert.

Additionally, you get the printout of output until the failure, and support for CLI scripts.

If you want to have consistent and safe error handling across environments, remove php_error.force_disabled on production server, and use 'display_errors' = 0 instead. You can also enable rich error messages during runtime, by using ini_set('display_errors', 1).

This way, your users won't see extensive debug information. But you can log all errors in your framework using callbacks, or send yourself an email if you want. And you can display a pretty user-facing error page in case something happens.

…ng the error in reportError.

It might be used to use additional loggers, or to display a nice error page for non-development users.
php_error will still catch all errors, but will not print them if display_errors is disabled. 
the same applies to ajax debugging
…ill be cleaned.

But outside buffers, like gz_output will be left in touch
Conflicts:
	src/php_error.php
Conflicts:
	src/php_error.php
Conflicts:
	src/php_error.php
Conflicts:
	src/php_error.php
Now it's generally useless, as php_error requires php 5.3
error_log, error_log_format and error_log_time_format
Conflicts:
	src/php_error.php
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant