如何打开magento错误消息? [英] How to turn on magento error messages?
问题描述
我已经安装了Magento社区版,并尝试创建我的第一个简单的hello world模块.几个小时后,我终于开始工作了.
I have installed Magento Community edition and tried creating my first simple hello world module. After a few hours I finally got it working.
我的问题是我在某些XML标签中使用了不正确的大小写.
My issues were I had used incorrect casing in some of the XML tags.
在尝试使其正常工作时,我试图加载该页面,但未显示一条消息,但没有错误.
While trying to get it to work I tried to load the page a not found message was displayed, but no error.
我在管理控制面板System > Configuration > Developer > Log Settings
中打开了错误,并写了一行我知道应该抛出错误的行,但我只是黑屏
I have switched errors on in the admin control panel System > Configuration > Developer > Log Settings
and wrote a line which I know should have thrown an error but I just got a blank screen
- 如何在Magento中显示错误?
- 当我在xml文件中使用不正确的大小写时,是否将其视为错误?或者这是我不会收到错误消息的问题?如果是这种情况,我将如何迅速找到引起该问题的文件(目前这显然不是问题,但是我可以想象,随着模块开始运行,将很难找到导致该问题的单个套管问题.问题)
推荐答案
用于启用错误报告
在索引"页面中更改以下内容:
In Index page change the following:
error_reporting(E_ALL | E_STRICT);
到
error_reporting(E_ALL);
设置$_SERVER['MAGE_IS_DEVELOPER_MODE'] = true
并取消注释此行
#ini_set('display_errors', 1);
在错误"文件夹中,将local.xml.sample
重命名为local.xml
.
In Errors folder rename local.xml.sample
to local.xml
.
希望获得帮助.
这篇关于如何打开magento错误消息?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!