Home  >  Article  >  Backend Development  >  How to open error prompt in php7

How to open error prompt in php7

王林
王林Original
2021-07-05 15:51:521997browse

The way to open the error prompt in php7 is to first uncomment the error prompt and error report. Then add [php_flag display_errors on] in the httpd.conf configuration file. Finally, restart the apache and php services.

How to open error prompt in php7

The operating environment of this article: windows10 system, php 7.3, thinkpad t480 computer.

The method to turn on the error prompt is as follows:

Remove the display_errors annotation and set the value to On

Remove the error_reporting annotation and set the value to E_ALL | E_STRICT

display_errors=On
error_reporting=E_ALL | E_STRICT

Modify the httpd.conf file and add the following settings in the last line

php_flag display_errors on
php_value error_reporting 2039

Restart the Apache service and the php service, and the error message will be displayed normally.

Related video tutorial sharing: php video tutorial

The above is the detailed content of How to open error prompt in php7. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn