Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

checkout_cart_product_add_after observer not firing in live server but working in local server
 
karthi skb
Jr. Member
 
Avatar
Total Posts:  5
Joined:  2012-06-05
Chennai
 

Hi,
I’m having some trouble in my module, it is working fine in local server but it’s not working in dev server.
Here is my code:
app/etc/modules/Ecophone_Specialoffer.xml

<?xml version="1.0"?>
<config>
    <
modules>
         <
Ecophone_Specialoffer>
            <
active>true</active>
            <
codePool>local</codePool>
        </
Ecophone_Specialoffer>
    </
modules>
</
config>
Config file
app/code/local/Ecophone/Specialoffer/etc/config.xml
<?xml version="1.0"?>
<config>
    <
modules>
      <
Ecophone_Specialoffer>
          <
version>0.1.0</version>
      </
Ecophone_Specialoffer>
    </
modules>
    <
frontend>
     <
events>
        <
checkout_cart_product_add_after>
            <
observers>
               <
Ecophone_Specialoffer_Model_Observer>
                  <
type>singleton</type>
                  <class>
Ecophone_Specialoffer_Model_Observer</class>
                  <
method>changingPrice</method>
               </
Ecophone_Specialoffer_Model_Observer>
           </
observers>
        </
checkout_cart_product_add_after>
    </
events>
    </
frontend>
</
config>
Observer.php
app/code/local/Ecophone/Specialoffer/Model/Observer.php

<?php
class Ecophone_Specialoffer_Model_Observer {
    
public function changingPrice(Varien_Event_Observer $obs){
             
die('hello');
        
}
}
 
Magento Community Magento Community
Magento Community
Magento Community
 
Nagamani Naresh
Jr. Member
 
Total Posts:  1
Joined:  2012-10-10
Madurai
 

Please Login to magento admin go to system->tools->compilation and click disable.

Now it will work in server.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top