Sending email with DKIM
Posted: 14 Oct 2017, 22:06
I have to admit that I am a bit confused why support for DKIM is STILL not added. I am patching this for years. PHPMailer supports it for years now. Still every time I want to upgrade I need to patch it again. Yes, it is just a few copy/pastes but it would be really nice not to have to do it at all. It is so simple...
Just add few global configs in config_inc.php
and patch email_send function in email_api.php:
Is there a reason why this is not in yet?
Just add few global configs in config_inc.php
Code: Select all
$g_DKIM_domain = 'example.com';
$g_DKIM_private = 'path/to/priv/key';
$g_DKIM_selector = 'mail.example;
$g_DKIM_passphrase = '';
$g_DKIM_identity = 'bt@example.com';
Code: Select all
if ( !is_blank( config_get( 'DKIM_domain' ) ) ) {
$t_mail->DKIM_domain = config_get( 'DKIM_domain' );
$t_mail->DKIM_private = config_get( 'DKIM_private' );
$t_mail->DKIM_selector = config_get( 'DKIM_selector' );
$t_mail->DKIM_passphrase = config_get( 'DKIM_passphrase' );
$t_mail->DKIM_identity = config_get( 'DKIM_identity' );
}