Custom replacement for mail() without full bridge
- adrianbj
- Member | 31
I know that you guys have the Nette Bridge which implements the MailSender class, but I am wondering if it might be possible to have a simpler approach to overriding the use of PHP's mail() without the need to build a full bridge?
Any thoughts or ideas on how something like this could / should be implemented?
Thanks.
- adrianbj
- Member | 31
Ok, well I finally got back to taking another look at this and discovered it's actually really easy using:
Debugger::getLogger()->mailer = function($message) {
// send $message using your own mail code here
};
Hope that helps someone else.
Last edited by adrianbj (2020-01-24 21:29)