Category: Magento

Magento Step by Step tutorials 0

How to get current customer id in Magento.?

To get the Current customer id in Magento you can use the following code to get the desired result. if(Mage::getSingleton(‘customer/session’)->isLoggedIn()) { $customerData = Mage::getSingleton(‘customer/session’)->getCustomer(); echo $customerData->getId(); }