$redirect_url = Mage::getUrl('customer/account/login/');
$current_url = Mage::helper('core/url')->getCurrentUrl();
if((!$this->helper('customer')->isLoggedIn()) && ($current_url != $redirect_url)){
Mage::app()->getFrontController()->getResponse()->setRedirect($redirect_url);
}
$current_url = Mage::helper('core/url')->getCurrentUrl();
if((!$this->helper('customer')->isLoggedIn()) && ($current_url != $redirect_url)){
Mage::app()->getFrontController()->getResponse()->setRedirect($redirect_url);
}
No comments:
Post a Comment