Saturday, March 28, 2015

Redirect to cms page after subscription of Newsletter

You can redirect to any page after subscription of newsletter.


Copy 
app\code\core\Mage\Newsletter\controllers\SubscriberController.php
to
app\code\local\Mage\Newsletter\controllers\SubscriberController.php


Open created file and search this code: $this->_redirectReferer();

and replace it to following code to redirect to your cms page.

$this->_redirectUrl(Mage::getBaseUrl().'cms-page-Identifier');


you can redirect it to base url by using following code instead of above.

$this->_redirectUrl(Mage::getBaseUrl());

No comments:

Post a Comment

Fatal error: Class Zend\Stdlib\Parameters contains 1 abstract method... magento 2

Fatal error: Class Zend\Stdlib\Parameters contains 1 abstract method and must therefore be declared abstract or implement the remaining met...