magento - Overriding account controller -


i try override function in controller /app/code/core/mage/customer/controllers/accountcontroller.php.

i create module folders:

/app/code/local/mandarin/skiplogoutsuccess/etc/config.xml

<?xml version="1.0" encoding="utf-8"?> <config>     <modules>         <mandarin_skiplogoutsuccess>             <version>0.1.0</version>         </mandarin_skiplogoutsuccess>     </modules>      <frontend>         <routers>             <checkout>                 <args>                     <modules>                         <mandarin_skiplogoutsuccess before="mage_customer">mandarin_skiplogoutsuccess</mandarin_skiplogoutsuccess>                     </modules>                 </args>             </checkout>         </routers>     </frontend> </config> 

/app/code/local/mandarin/skiplogoutsuccess/controllers/accountcontroller.php

require_once 'mage/customer/controllers/accountcontroller.php';  class mandarin_skiplogoutsuccess_accountcontroller extends mage_customer_accountcontroller {     public function logoutaction()     {         $this->_getsession()->logout()->setbeforeauthurl(mage::geturl());         mage::log("its allive!", null, 'mygento.log');         $this->_redirecturl(mage::geturl());     } } 

/app/etc/modules/mandarin_skiplogoutsuccess.xml

<?xml version="1.0"?>  <config>     <modules>          <mandarin_skiplogoutsuccess>               <active>true</active>                <codepool>local</codepool>           </mandarin_skiplogoutsuccess>     </modules>  </config> 

when run logoutaction controller used core. in log file don`t message. error?

i think made copy-paste error:

in config.xml reference namespace "<checkout>" should "<customer>" (and of course closing tag too)


Comments

Popular posts from this blog

Perl - how to grep a block of text from a file -

delphi - How to remove all the grips on a coolbar if I have several coolbands? -

javascript - Animating array of divs; only the final element is modified -