In our site user must login to check the products. we are checking login session in header(header.phtml) and based on that we are redirecting.
if(!$this->helper('customer')->isLoggedIn()){
Mage::app()->getFrontController()->getResponse()->setRedirect(Mage::getUrl('customer/account/login'));
}
Suppose after login if keep the page open for sometime and after sometime if i click on menu/search/detail page it will not redirect to login page. If session times out it should redirect to login page but It gives error. Please check below error page and suggest.
Thanks
Solved! Go to Solution.
Hi @aroorkarthik,
Since that seems to be a custom development it's a little bit hard to understand why you're getting the failure.
I guess you should check on your custom module if the customer is still logged in to handle the redirect properly (but I'm just gessing)
Hi @aroorkarthik,
Since that seems to be a custom development it's a little bit hard to understand why you're getting the failure.
I guess you should check on your custom module if the customer is still logged in to handle the redirect properly (but I'm just gessing)