Set error reporting level to maximum

Configure your development environment to display all PHP warnings, notices and errors. This will help you code better and also help in catching potential bugs early in development phase.

You can change the error reporting level at runtime by adding the following code at the top of your PHP script:

// Report all PHP errors.
// Don't enable on production servers

You can also control whether you want to display errors in the browser itself or whether you want to log the errors.

Note: Displaying errors is not recommended for production servers.

Permanent link to this article:

Leave a Reply

Your email address will not be published.