magento标头已在mage.php中发送


magento headers already sent in mage.php

我试图在我的magento中安装一个缓存模块,并将一些代码粘贴到我的local.xml中(以启用后端缓存),现在我收到了这些错误。

There has been an error processing your request
Cannot send headers; headers already sent in Mage.php, line 767
Trace:
0 /home1/devirona/public_html/includes/src/__default.php(32045): Varien_Data_Collection_Db->setConnection(false)
1 /home1/devirona/public_html/includes/src/__default.php(24081): Mage_Core_Model_Resource_Db_Collection_Abstract->__construct(Object(Mage_Core_Model_Resource_Website))
2 /home1/devirona/public_html/includes/src/__default.php(24113): Mage_Core_Model_Config->getModelInstance('core_resource/w...', Object(Mage_Core_Model_Resource_Website))
3 /home1/devirona/public_html/app/Mage.php(491): Mage_Core_Model_Config->getResourceModelInstance('core/website_co...', Object(Mage_Core_Model_Resource_Website))
4 /home1/devirona/public_html/includes/src/__default.php(5861): Mage::getResourceModel('core/website_co...', Object(Mage_Core_Model_Resource_Website))
5 /home1/devirona/public_html/includes/src/__default.php(5866): Mage_Core_Model_Abstract->getResourceCollection()
6 /home1/devirona/public_html/includes/src/__default.php(20959): Mage_Core_Model_Abstract->getCollection()
7 /home1/devirona/public_html/includes/src/__default.php(20817): Mage_Core_Model_App->_initStores()
8 /home1/devirona/public_html/includes/src/__default.php(20700): Mage_Core_Model_App->_initCurrentStore('', 'store')
9 /home1/devirona/public_html/app/Mage.php(684): Mage_Core_Model_App->run(Array)
10 /home1/devirona/public_html/index.php(87): Mage::run('', 'store')
11 {main}

我试图撤销我所做的一切,但都是徒劳的。

<?xml version="1.0"?>
<!--
/**
 * Magento
 *
 * NOTICE OF LICENSE
 *
 * This source file is subject to the Academic Free License (AFL 3.0)
 * that is bundled with this package in the file LICENSE_AFL.txt.
 * It is also available through the world-wide-web at this URL:
 * http://opensource.org/licenses/afl-3.0.php
 * If you did not receive a copy of the license and are unable to
 * obtain it through the world-wide-web, please send an email
 * to license@magentocommerce.com so we can send you a copy immediately.
 *
 * DISCLAIMER
 *
 * Do not edit or add to this file if you wish to upgrade Magento to newer
 * versions in the future. If you wish to customize Magento for your
 * needs please refer to http://www.magentocommerce.com for more information.
 *
 * @category   Mage
 * @package    Mage_Core
 * @copyright  Copyright (c) 2008 Irubin Consulting Inc. DBA Varien (http://www.varien.com)
 * @license    http://opensource.org/licenses/afl-3.0.php  Academic Free License (AFL 3.0)
 */
-->
<config>
    <global>
        <install>
            <date><![CDATA[Tue, 02 Sep 2014 14:04:20 +0000]]></date>
        </install>
        <crypt>
            <key><![CDATA[asdasdasda]]></key>
        </crypt>
        <disable_local_modules>false</disable_local_modules>
        <resources>
            <db>
                <table_prefix><![CDATA[dv_]]></table_prefix>
            </db>
            <default_setup>
                <connection>
                    <host><![CDATA[localhost]]></host>
                    <username><![CDATA[devirona]]></username>
                    <password><![CDATA[*********]]></password>
                    <dbname><![CDATA[devirona_store]]></dbname>
                    <initStatements><![CDATA[SET NAMES utf8]]></initStatements>
                    <model><![CDATA[mysql4]]></model>
                    <type><![CDATA[pdo_mysql]]></type>
                    <pdoType><![CDATA[]]></pdoType>
                    <active>1</active>
                </connection>
            </default_setup>
        </resources>
        <session_save><![CDATA[files]]></session_save>
        
	
		<cache>
			<backend>Netzarbeiter_Cache_Model_Symlink</backend>
			<backend_options>
				<cache_dir>var/cache</cache_dir>
				<hashed_directory_level>1</hashed_directory_level>
				<hashed_directory_umask>0777</hashed_directory_umask>
				<file_name_prefix>mage</file_name_prefix>
			</backend_options>
		</cache>
	
        
    </global>
    <admin>
        <routers>
            <adminhtml>
                <args>
                    <frontName><![CDATA[admin]]></frontName>
                </args>
            </adminhtml>
        </routers>
    </admin>

这是我的local.xml

我找不出是什么原因导致了这个错误。。我添加了缓存代码。首先,我在配置关闭后添加了它。。。然后我更改了它。在将代码放回配置之前,我保存了它并尝试运行它,然后我得到了问题

首先尝试禁用编译器,方法是转到/included/config.php并注释掉以下行:

define('COMPILER_INCLUDE_PATH', dirname(__FILE__).DIRECTORY_SEPARATOR.'src');
define('COMPILER_COLLECT_PATH', dirname(__FILE__).DIRECTORY_SEPARATOR.'stat');

然后尝试刷新缓存(通过删除var/cache目录),看看它是否有帮助。