Magento 1.9- How to check user login or not in magento

How to check user login or not in magento.

Below is the simple code to check user login or not in magento.


$myStatus = Mage::getSingleton('customer/session')->isLoggedIn();
if($myStatus):
  echo 'Loogedin';
else:
   echo 'Not Loogedin';
endif;

No comments:

Post a Comment