4

By default, when a customer buys something on my website (Magento 1.9) he receives an order confirmation via email. The thing is I'm using another platform to send my emails to the customer. So I don't want magento to send emails to the customer. I want to be the only one (the admin) notified when someone buys something.

So how can I make magento to send order email only to the admin and not the customer ? Maybe I have to modify some files, but I dont know which one...

I really need some help. Thank you !

3

New order email are sent when the method Mage/Sales/Model/Order.php:queueNewOrderEmail is called.

If you look this method, you will see that there is a configuration setting sales_email/order/enabled to enable/disable this email but it seems that you don't want to disable it.

To modify the destination email, I guess you will have to rewrite the Mage/Sales/Model/Order.php and its method queueNewOrderEmail.

In your rewritten method, you will have to replace $emailInfo->addTo($this->getCustomerEmail(), $customerName); by $emailInfo->addTo(<the-email-you-want>, <the-name-you-want>);.

Hope it helps.

  • I think we are getting close to the solution, but unfortunately it is not working. The emails are still being sent to the customer... – Steeve Mar 9 '18 at 17:12
  • Do you have any other idea @Julien ? – Steeve Mar 15 '18 at 23:02
0

simply go to your magento admin panel >> system >> configuration >> sales >> transactions emails >> order >> set to unable. This way, the system will not shoot an emails after a new order is processed. Do the same for other stuffs like order updated and so

  • Its not the right solution because no emails will be sent not even to the admin. And I want to be the only one notified when someone place an order – Steeve Mar 9 '18 at 17:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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