Home >Backend Development >PHP Tutorial >php如何显示错误信息

php如何显示错误信息

WBOY
WBOYOriginal
2016-06-23 13:30:091184browse

php默认不打印错误,如需打印,

vi $PHP_HOME/etc/php.ini, 修改以下几项:

display_errors = Onerror_reporting = E_ALL & ~E_NOTICE

如果有设error_log变量,注释掉输出到error_log这句话就可以将错误直接显示在terminal了

然后重启php:

$PHP_HOME/sbin/php-fpm start

版权声明:本文为博主原创文章,未经博主允许不得转载。

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