Magento 1.9 – How to Remove Logout Page

logoutmagento-1.9

Is it possible to bypass the logout page in Magento. I don't want to show the logout success page, want to show the current page

Best Answer

You can do it by using below code

override app/code/core/Mage/Customer/controllers/AccountController.php

There is a logoutAction

public function logoutAction()
    {
        $this->_getSession()->logout()
            ->renewSession();

        $this->_redirect('*/*/logoutSuccess');
    }

changed to

public function logoutAction()
    {
        $this->_getSession()->logout()
            ->renewSession();

        $this->_redirectReferer(); //it will redirect to your previous page
    } 
Related Topic