How to get customer mail address who have added the product to their wish list in Magento. I don't want session customer mail id.? please help me.
closed as unclear what you're asking by Fabian Blechschmidt, Keyul Shah, Marius♦, Mufaddal, davidalger Mar 25 '14 at 14:13
Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
The following will load the wishlist of id 1 and join it to the customer table so that you will also get the email address in the collection results.
/** @var Mage_Wishlist_Model_Wishlist $wishlist */ $wishlist = Mage::getModel('wishlist/wishlist'); /** @var Mage_Wishlist_Model_Resource_Wishlist_Collection $wishlistCollection */ $wishlistCollection = $wishlist->getCollection(); $wishlistCollection->addFieldToFilter($wishlist->getIdFieldName(), 1); $wishlistCollection->join( array('customer' => $wishlistCollection->getConnection()->getTableName('customer/entity')), 'main_table.customer_id = customer.entity_id' );
You can join customer attribute with email and wishlist table by customer_id