Bogs Imba
Bogs Imba

Reputation: 59

Magento send outgoing email to specific email address for testing

Is there an Admin Settings where i can set all the outgoing email to a specific email address.

The reason is in my development of Magento, i am using db from production and there are email addresses from real users which i do not want to acccidentaly send a message to them while im developing..

For example in subscribers, i want to send a newsletter but all emails should go to the email address i will set..

If no admin settings, i have no choice but to create migration script and update related tables that contains the email addresses..

Magento experts, any advice?

Upvotes: 1

Views: 353

Answers (1)

McNab
McNab

Reputation: 6777

There's nothing in the admin settings for this. You are making a wise move though, having live customer information in a dev site can be dangerous. It's also a risk for the business, the customer details can be valuable so you really don't want them kicking around in a dev database at all imo.

There's a great set of tools for managing Magento from the command line

https://github.com/netz98/n98-magerun

Deleting the live customers and replacing them with dummies is one of the many options you've got;

https://github.com/netz98/n98-magerun#user-content-delete-customers

https://github.com/netz98/n98-magerun#user-content-generate-dummy-customers

So to delete all your live customers in the dev site you'd do;

php n98-magerun.phar customer:delete --all

from the command line once you've followed the instructions and downloaded the script to your Magento root.

Upvotes: 0

Related Questions