php - How can I redirect inside helper class -
in magento, have helper class data
class my_advert_helper_data extends mage_core_helper_abstract { where
i have function such
    public function callvalid($arrerror){ ..... and in function trying redirect user login...
$this->_redirect($strreturnpath); the seturl not redirecting. how can redirect?.. $strreturnpath getting */ path. need go homepage receiving error below
fatal error: call undefined method my_advert_helper_data::_redirect() in  
you can set redirects within helper class following
 mage::app()->getresponse()->setredirect($strreturnpath); that should trick.
Comments
Post a Comment