How to display/hide strict/all errors in php?

If you need to display all php errors on the web-page before production, you can use it settings
For display ALL errors/notices/warnings/deprecated info:
If you have access to php.ini then you can change 2 params.
Example (in php.ini) ↓

error_reporting = E_ALL
display_errors = On

Often, you need to check a separate part of functional and you don’t want display errors on the all site.
In this way, you can insert 2 lines in your php file with debug functional.
Example ↓

//Show all errors, notices
error_reporting(E_ALL);
ini_set('display_errors', 1);

Note: Display errors could be turned off in the php.ini or your Apache config file.
Continue reading How to display/hide strict/all errors in php?