0

I am getting error: Fatal error: Class 'Mage_Assel_Holidays_Helper_Data' not found

Here is config.xml--

<?xml version="1.0" encoding="UTF-8"?>
<config>
  <modules>
        <Assel_Holidays>
            <version>1.0.0</version>
        </Assel_Holidays>
   </modules>
   <admin>
        <routers>
            <holidays>
                <use>admin</use>
                <args>
                    <module>Assel_Holidays</module>
                    <frontName>holi</frontName>
                </args>
            </holidays>
        </routers>
   </admin>
   <frontend>
        <routers>
            <holidays>
                <use>standard</use>
                <args>
                    <module>Assel_Holidays</module>
                    <frontName>holidays</frontName>
                </args>
            </holidays>
        </routers>
    </frontend>
   <global>
      <helpers>
            <holidays>
                <class>Assel_Holidays_Helper</class>
            </holidays>
      </helpers>
      <blocks>
            <holidays>
                <class>Assel_Holidays_Block</class>
            </holidays> 
      </blocks>
   </global>
</config> 

I have helper class in Data.php in Assel/Holidays/Helper/ folder.

Here is the Data.php

<?php
class Assel_Holidays_Helper_Data extends Mage_Core_Helper_Abstract
{

}

Here is the app/etc/modules/Assel_Holidays.xml--

<?xml version="1.0" encoding="utf-8"?>
<config>
    <modules>
        <Assel_Holidays>
          <active>true</active>
          <codePool>local</codePool>
        </Assel_Holidays>
    </modules>
</config>

I couldn't found out what is the reason behind it.

7
  • DO You define Data.php at Assel/Holidays/Helper?
    – Amit Bera
    Commented Feb 10, 2016 at 10:05
  • Please check my edits Commented Feb 10, 2016 at 10:06
  • 1
    Seems like you are calling your helper this way: Mage::helper('assel_holidays') instead of Mage::helper('holidays') check your code Commented Feb 10, 2016 at 10:09
  • I am not calling like this Mage::helper('holidays') anywhere Commented Feb 10, 2016 at 10:11
  • is your CodePoll correctly configured, look into app/etc/modules/Assel_Holidays.xml which codePool is configured there ?
    – roman204
    Commented Feb 10, 2016 at 10:16

1 Answer 1

1

I am not calling like this Mage::helper('holidays') anywhere

Then you use it indirectly with translation of XML nodes. Please check your system.xml and/or adminhtml.xml files and replace module="Assel_Holidays" with module="holidays"

In XML files (config.xml, system.xml, layout) you can specify if nodes should be translated with the translate attribute. You should also add the module attribute to specify the scope, but here the value has to be the helper alias, not the module name as above.

<one_column module="page" translate="label">
    <label>1 column</label>
    <template>page/1column.phtml</template>
    <layout_handle>page_one_column</layout_handle>
    <is_default>1</is_default>
</one_column>

Learn more: How to implement translations in design template package CSV's? How does echo $this->__('Text') work?

1
  • nice explanation Fabian
    – Amit Bera
    Commented Feb 10, 2016 at 13:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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