博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
打印php错误日志,php怎样打印错误日志
阅读量:1532 次
发布时间:2019-04-21

本文共 567 字,大约阅读时间需要 1 分钟。

php打印错误日志的方法:1、编辑php-fpm.conf配置文件;2、修改php.ini配置文件;3、重启php-fpm;4、在脚本中添加【ini_set('display_errors', 0);】。

20200813_5f3496a20dad1.jpg

具体方法:

(推荐教程:php图文教程)

1、修改php-fpm.conf配置文件

catch_workers_output = yes error_log = log/php_error.log

2、修改php.ini配置文件

log_errors = on error_log = /user/local/php/log/error_log

3、重启php-fpm

(视频教程推荐:php视频教程)

注意:如果php.ini文件找不到,请在页面输出phpinfo()可以查到。php错误日志不输出到日志和屏幕上

4、在配置文件php.ini中修改

display_errors = off log_error = on error_reprting = E_ALL

5、在程序中修改

ini_set('display_errors', 0); ini_set('error_reporting', E_ALL); ini_set('error_log', '日志文件'); ini_set('log_errors', 1);

转载地址:http://elkdy.baihongyu.com/

你可能感兴趣的文章
【 Notes 】SOURCE LOCALIZATION PREVIEW
查看>>
【 Overview 】MEASUREMENT MODELS AND PRINCIPLES FOR SOURCE LOCALIZATION
查看>>
【 Notes 】TOA Measurement Model
查看>>
【 Overview 】ALGORITHMS FOR SOURCE LOCALIZATION
查看>>
【 Notes 】NLS ALGORITHMS of TOA - Based Positioning
查看>>
【 NLS 】Newton – Raphson Iteration Procedure of TOA - Based Positioning
查看>>
【 NLS 】Gauss-Netwon algorithm Iteration Procedure of TOA - Based Positioning
查看>>
【 NLS 】Steepest Descent Algorithm Iteration Procedure of TOA - Based Positioning
查看>>
【 Notes 】ML ALGORITHMS of TOA - Based Positioning
查看>>
【 ML 】Newton – Raphson Iteration Procedure of TOA - Based Positioning Simulation
查看>>
【 ML 】 Gauss – Newton Iteration Procedure of TOA - Based Positioning Simulation
查看>>
【 ML 】Steepest Descent Iteration Procedure of TOA - Based Positioning Simulation
查看>>
【 LLS 】Linear Approaches of TOA - Based Positioning
查看>>
【 MATLAB 】 LLS algorithm Simulation of TOA - Based Positioning
查看>>
【 MATLAB 】 WLLS algorithm Simulation of TOA - Based Positioning
查看>>
【 MATLAB】 Two-step WLS algorithm Simulation of TOA - Based Positioning
查看>>
【 MATLAB】Subspace algorithm Simulation of TOA - Based Positioning
查看>>
【 Notes 】WLLS Algorithm of TOA - Based Positioning (include the two - step WLS estimator)
查看>>
【 Notes 】Best linear unbiased estimator(BLUE) approach for time-of-arrival based localisation
查看>>
Heron's formula
查看>>