3

case 1 : when i register via Facebook,i need to confirm the user and activate the newsletter subscription programmatically.

your support will help much more, thanks advance.

closed as unclear what you're asking by 7ochem, Marius May 11 '15 at 11:51

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.

1

You can do this easily :

$customer=Mage::getModel('customer/customer')->setWebsiteId(Mage::app()->getStore()->getWebsiteId())->loadByEmail($email);
$customer->setConfirmation(true);
$customer->save();

for case of newsletter subscription try below:

$customer->setIsSubscribed(true);
    $customer->save();

Not the answer you're looking for? Browse other questions tagged or ask your own question.