magento create customer code April 17, 2013/0 Comments/in Uncategorized /by puneetk00 magento create customer $customer = Mage::getModel(‘customer/customer’); $password = ‘test1234’; $email = ‘dtest@gmail.com’; $customer->setWebsiteId(Mage::app()->getWebsite()->getId()); $customer->loadByEmail($email); if(!$customer->getId()) { $groups = Mage::getResourceModel(‘customer/group_collection’)->getData(); $groupID = ‘3’; $customer->setData( ‘group_id’, $groupID ); $customer->setEmail($email); $customer->setFirstname(‘test’); $customer->setLastname(‘testing’); $customer->setPassword($password); $customer->setConfirmation(null); $customer->save(); echo $customer->getId(); } Puneet Kumar Magento Developer http://mg2dev.com/wp-content/uploads/2023/06/logo-transparent-png-300x86.png 0 0 puneetk00 http://mg2dev.com/wp-content/uploads/2023/06/logo-transparent-png-300x86.png puneetk002013-04-17 13:16:002013-04-17 13:16:00magento create customer code
Leave a Reply
Want to join the discussion?Feel free to contribute!