Feature request: Debug email setting
Permalink
In my packages I have my own email class which will read the Apache Env Var 'PLATFORM' which will be set in .htaccess to e.g. local, dev, staging, production. In turn this will read from a define in the Package controller e.g.
The email class dutifully takes an email override, if set, from the defined settings for the platform where it's running and, if set, sends ALL generated email by that class to that address. This allows development to not have to worry about spamming real live accounts when in dev/testing - especially when integrating with third party systems which contain real customer emails.
Unfortunately the C5 system generated emails, e.g. registration validation will always send to the user address.
I propose a new feature whereby the debug settings page allows for a systemwide development/testing email address to be set which could contain multiple email comma-separated destinations (or an Add Email UI widget). C5 would, when set appropriately always send email to the address(es) in that setting and never elsewhere.
There are probably other C5 settings that would benefit from a Debug-Override-Setting approach too but the email is certainly an important one.
define('SETTINGS', [ 'LOCAL' => [ 'email_override' => 'mytestemail@somewhere.com' ] 'DEV' => [ 'email_override' => 'myothertestemail@somewhere.com' ] ]);
The email class dutifully takes an email override, if set, from the defined settings for the platform where it's running and, if set, sends ALL generated email by that class to that address. This allows development to not have to worry about spamming real live accounts when in dev/testing - especially when integrating with third party systems which contain real customer emails.
Unfortunately the C5 system generated emails, e.g. registration validation will always send to the user address.
I propose a new feature whereby the debug settings page allows for a systemwide development/testing email address to be set which could contain multiple email comma-separated destinations (or an Add Email UI widget). C5 would, when set appropriately always send email to the address(es) in that setting and never elsewhere.
There are probably other C5 settings that would benefit from a Debug-Override-Setting approach too but the email is certainly an important one.