Newsletter Subscribed but No Confirmation Email – Magento 1.7.0.2

ce-1.7.0.2emailnewsletter

If I subscribe to the newsletter as guest I get a email to confirm my subscribtion but after I confirm I don't get a confirmation mail that I am subscribed now.

How can I change this to get the confirmation mail?

enter image description here

Best Answer

As Sander Mangel pointed out the solution is in app/code/core/Mage/Newsletter/Model/Subscriber.php. Copy this file to app/code/local/Mage/Newsletter/Model/Subscriber.php

Find function confirm($code) (Line 470 in CE-1.7.0.2) and add $this->sendConfirmationSuccessEmail();

Now the function should look like this:

public function confirm($code)
{
    if($this->getCode()==$code) {
        $this->setStatus(self::STATUS_SUBSCRIBED)
            ->setIsStatusChanged(true)
            ->save();
        // This is new:
        $this->sendConfirmationSuccessEmail();
        return true;
    }

    return false;
}
Related Topic