1

I have installed one module extension which throws an fatal error Fatal error: Class 'Mage_Clarion_Customerattribute_Helper_Data' not found in .../app/Mage.php on line 547 when i clicked on "Manage Attributes".

Following my \app\etc\modules\Clarion_Customerattribute.xml file

<config>
<modules>
    <Clarion_Customerattribute>
        <active>true</active>
        <codePool>community</codePool>
    </Clarion_Customerattribute>
</modules>
</config>

Following my \app\code\community\Clarion\Customerattribute\etc\config.xml file

<config>
<modules>
    <Clarion_Customerattribute>
        <version>0.1.0</version>
    </Clarion_Customerattribute>
</modules>

<global>
    <models>
        <clarion_customerattribute>
            <class>Clarion_Customerattribute_Model</class>
        </clarion_customerattribute>
    </models>
    <helpers>
        <clarion_customerattribute>
            <class>Clarion_Customerattribute_Helper</class>
        </clarion_customerattribute>  
    </helpers>
    <blocks>
        <clarion_customerattribute>
            <class>Clarion_Customerattribute_Block</class>
        </clarion_customerattribute>
    </blocks>
</global>

<frontend>
    <layout>
        <updates>
            <clarion_customerattribute>
                    <file>clarion_customerattribute.xml</file>
            </clarion_customerattribute>
        </updates>
    </layout>
</frontend>

<adminhtml>
    <layout>
        <updates>
            <clarion_customerattribute>
                <file>clarion_customerattribute.xml</file>
            </clarion_customerattribute>
        </updates>
    </layout>
</adminhtml>

<admin>
    <routers>
        <adminhtml>
            <args>
                <modules>
                    <clarion_customerattribute after="Mage_Adminhtml">Clarion_Customerattribute_Adminhtml</clarion_customerattribute>
                </modules>
            </args>
        </adminhtml>
    </routers>
</admin>
<!-- Clarion_Customerattribute_Adminhtml indicates the path of the admin controller-->
<default>
    <general>
        <validator_data>
            <input_types>
                <text>text</text>
                <textarea>textarea</textarea>
                <date>date</date>
                <boolean>boolean</boolean>
                <multiselect>multiselect</multiselect>
                <select>select</select>
            </input_types>
        </validator_data>
    </general>
</default>
</config>

Following my \app\code\community\Clarion\Customerattribute\etc\adminhtml.xml file

<config>
<menu>
    <customer>
        <children>
            <customer_attribute translate="title" module="clarion_customerattribute">
                <title>Manage Attributes</title>
                <sort_order>601</sort_order> 
                <action>adminhtml/customerattribute</action>
            </customer_attribute>
        </children>
    </customer>
</menu>
<!-- Aceess permission for the node admin/customer/customer_attribute-->
<acl>
    <resources>
        <all>
            <title>Allow Everything</title>
        </all>
        <admin>
            <children>
                <customer>
                    <children>
                        <customer_attribute translate="title" module="clarion_customerattribute">
                            <title>Manage Attributes</title>
                            <sort_order>601</sort_order> 
                                <children>
                                    <save translate="title">
                                        <title>Save Attribute</title>
                                        <sort_order>0</sort_order> 
                                    </save>
                                    <delete translate="title">
                                        <title>Delete Attribute</title>
                                        <sort_order>0</sort_order> 
                                    </delete>
                                </children>
                        </customer_attribute>
                    </children>
                </customer>
            </children>
        </admin>
    </resources>
</acl>
</config>

Here is \app\code\community\Clarion\Customerattribute\controllers\Adminhtml\CustomerattributeController.php

class Clarion_Customerattribute_Adminhtml_CustomerattributeController extends Mage_Adminhtml_Controller_Action
{
    protected function _initAction()
    {

         $this->_title($this->__('Customer'))->_title($this->__('Attributes'))->_title($this->__('Manage Attributes'));

         if($this->getRequest()->getParam('popup')) 
         {
            $this->loadLayout('popup');
         } 
         else 
         {
            $this->loadLayout()
        ->_setActiveMenu('customer/customer_attribure')
                ->_addBreadcrumb(Mage::helper('clarion_customerattribute')->__('Customer'), Mage::helper('clarion_customerattribute')->__('Customer'))
                ->_addBreadcrumb(
                    Mage::helper('clarion_customerattribute')->__('Manage Customer Attributes'),
                        Mage::helper('clarion_customerattribute')->__('Manage Customer Attributes'));
         }
         return $this;
          public function indexAction() 
          {
                $this->_initAction()->renderLayout();
          }
}

Here, \app\code\community\Clarion\Customerattribute\Helper\Data.php

class Clarion_Customerattribute_Helper_Data extends Mage_Core_Helper_Abstract
{   
//some code;
}

I tried to empty /var/cache folder. but it not work. I also tried to replace clarion_customerattribute to customerattribute in CustomerattributeController.php file but it not work.

Please help me for solving this problem (Fatal Error)

  • please post full module.. – Amit Bera Oct 3 '15 at 15:24
  • Is your compilation enabled? If yes - please recompile. – michael Oct 3 '15 at 16:52
  • @michael i also tried your suggestion – Hardik Visa Oct 5 '15 at 3:34
0

Clarion_Customerattribute.xml

<?xml version="1.0"?>
<config>
<modules>
    <Clarion_Customerattribute>
        <active>true</active>
        <codePool>local</codePool>
        <version>0.1.0</version>
    </Clarion_Customerattribute>
</modules>
</config>

config.xml

<?xml version="1.0"?>
<config>
<modules>
    <Clarion_Customerattribute>
        <version>0.1.0</version>
    </Clarion_Customerattribute>
</modules>

<global>
    <models>
        <clarion_customerattribute>
            <class>Clarion_Customerattribute_Model</class>
        </clarion_customerattribute>
    </models>
    <helpers>
      <clarion_customerattribute>
        <class>Clarion_Customerattribute_Helper</class>
      </clarion_customerattribute>
    </helpers>
    <blocks>
        <clarion_customerattribute>
            <class>Clarion_Customerattribute_Block</class>
        </clarion_customerattribute>
    </blocks>
</global>

<frontend>
    <layout>
        <updates>
            <clarion_customerattribute>
                    <file>clarion_customerattribute.xml</file>
            </clarion_customerattribute>
        </updates>
    </layout>
</frontend>

<adminhtml>
    <layout>
        <updates>
            <clarion_customerattribute>
                <file>clarion_customerattribute.xml</file>
            </clarion_customerattribute>
        </updates>
    </layout>
</adminhtml>

<admin>
    <routers>
        <adminhtml>
            <args>
                <modules>
                    <clarion_customerattribute after="Mage_Adminhtml">Clarion_Customerattribute_Adminhtml</clarion_customerattribute>
                </modules>
            </args>
        </adminhtml>
    </routers>
</admin>
<!-- Clarion_Customerattribute_Adminhtml indicates the path of the admin controller-->
<default>
    <general>
        <validator_data>
            <input_types>
                <text>text</text>
                <textarea>textarea</textarea>
                <date>date</date>
                <boolean>boolean</boolean>
                <multiselect>multiselect</multiselect>
                <select>select</select>
            </input_types>
        </validator_data>
    </general>
</default>
</config>

adminhtml.xml

<?xml version="1.0"?>
<config>
<menu>
    <customer>
        <children>
            <customer_attribute translate="title" module="clarion_customerattribute">
                <title>Manage Attributes</title>
                <sort_order>601</sort_order> 
                <action>adminhtml/customerattribute</action>
            </customer_attribute>
        </children>
    </customer>
</menu>
<!-- Aceess permission for the node admin/customer/customer_attribute-->
<acl>
    <resources>
        <all>
            <title>Allow Everything</title>
        </all>
        <admin>
            <children>
                <customer>
                    <children>
                        <customer_attribute translate="title" module="clarion_customerattribute">
                            <title>Manage Attributes</title>
                            <sort_order>601</sort_order> 
                                <children>
                                    <save translate="title">
                                        <title>Save Attribute</title>
                                        <sort_order>0</sort_order> 
                                    </save>
                                    <delete translate="title">
                                        <title>Delete Attribute</title>
                                        <sort_order>0</sort_order> 
                                    </delete>
                                </children>
                        </customer_attribute>
                    </children>
                </customer>
            </children>
        </admin>
    </resources>
</acl>
</config>

Data.php

<?php 
class Clarion_Customerattribute_Helper_Data extends Mage_Core_Helper_Abstract
{   
//some code;
}

enter image description here

  • @quisar sorry its my mistake it already closed in original code. – Hardik Visa Oct 5 '15 at 6:26
  • i tested it by my self there were two addition i added in that – Qaisar Satti Oct 5 '15 at 6:30
  • @quisar thank you for your response i tried but not working. it still give same error.... – Hardik Visa Oct 5 '15 at 6:42
  • it working on my side it will give you all code.. – Qaisar Satti Oct 5 '15 at 6:43
  • its work in your magento but not in my magento 1.9.0.1 – Hardik Visa Oct 5 '15 at 9:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.