1

Upgrading to a new server has brought a lot of PHP errors. My site has a lot of different includes, so instead of tracking down and adding error_reporting (E_ALL ^ E_NOTICE); Is there a better way I can remove these errors?

2 Answers 2

4
ini_set('display_errors', 'off');
error_reporting(0);
Sign up to request clarification or add additional context in comments.

Comments

1

Edit your php.ini file and set:

error_reporting = 32759

If you're using Apache, you can also set it in httpd.conf or a .htaccess file:

php_value error_reporting 32759

The numbers are looked up from: http://php.net/errorfunc.constants

2 Comments

Can't find the number 32759 at this site. Where do you get this number?
Ok, I find my answer here: stackoverflow.com/questions/4678082/…

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.