让php显示错误信息

2013-12-05 14:36:40

[工作记录 | Work Record] ,

有时候不能够改动php.ini 的时候,这个方法就特别有用了,

 

将它加在页面的最上方,就可以看到所有的错误信息.

 

 

这里运用的方法是通过ini_set()函数,

来对php.ini中的设置进行临时的改动.

 

<?php
ini_set("display_errors", true);
error_reporting(E_ALL);
?>

 

 

这篇博文发表在 工作记录 | Work Record 目录下,标签为 ,
如需引用,请使用链接:https://note.mc256.dev/?p=150

This article published in 工作记录 | Work Record with tags , .
Cite this page using this link:https://note.mc256.dev/?p=150

您的邮箱地址不会被公开,评论使用Gravatar头像。
Your email address will not be published. This blog is using Gravatar.

正在提交评论... Submitting ...
正在为您准备评论控件 Loading Comment Plugin
Copyright © 2013-2024 mc256. All Rights Reserved.
Powered by WordPress on top of a dual-stack k3s Cluster using JuiceFS.
Wordpress Theme Designed By mc256.
Encrypted By Let's Encrypt.  Hosted On Linode + OVH + AWS.
DNS Provided By Hostker.
Status Page by CloudFlare Worker.