How can I directly display the error message? My development environment ubuntu16.04php7.0.7php-fpmng.pdf now only outputs aninternalservererroccurred when code errors occur. I hope to display the error information directly on the webpage for development convenience. Thank you. How can I directly display the error message?
My development environment is ubuntu 16.04 php 7.0.7 php-fpm nginx
When a code error occurs, onlyAn internal server error occurred.
It is hoped that the error information can be displayed directly on the webpage for convenient development. Thank you.
Reply content:
How can I directly display the error message?
My development environment is ubuntu 16.04 php 7.0.7 php-fpm nginx
When a code error occurs, onlyAn internal server error occurred.
It is hoped that the error information can be displayed directly on the webpage for convenient development. Thank you.
Set_error_handler registers the error handling mechanism
Set_exception_handler registers the exception handling mechanism
These two methods can intercept you when an error occurs and add them to your own logic.
Enable all error messages .. One more step is required for php-fpm, that is, the error display should be opened in the configuration file of php-fpm.