Magento Themes and Magento Extensions

How long customer is inactive ?

Share

How long customer is inactive ?

1 $customer = Mage::getSingleton('customer/session')->getCustomer();
2 $log = Mage::getModel('log/customer')->load($customer->getId());
3 $inctive_time = now() - $log->getLastVisitAt();

Comments are closed.