Tuesday, October 7, 2014

Prestashop - Solving common email related issues


There are some common email related issues in Prestashop. Some of them are when we do registration, forgot password etc they say email has been set, but we may not receive it. 


The issue can be due to the below reasons.
  • "From" field doesn't match your domain.
  • Incompatible additional headers.

Below are solutions to both:

In /tools/swift/Swift/Message.php line #79
Change

$this->setFrom("");
To
$this->setFrom("youremail@yourdomainname.com");

In /tools/swift/Swift.php after line 370
if (!($has_reply_to = $message->getReplyTo())) $message->setReplyTo($from);
 
Add the following code:
if (!$has_reply_to[0])
$message->setReplyTo($from->getAddress());

Now try sending a contact message....

If it still doesn’t work, make the following change:
In /tools/swift/Swift/Plugin/MailSend.php line # 159
Add


$params = "";

Popular Posts