1
0
mirror of https://github.com/e107inc/e107.git synced 2025-07-30 11:20:25 +02:00

Send SMTP port number in test email.

This commit is contained in:
Cameron
2016-04-08 09:34:08 -07:00
parent 433f8a6aed
commit 85d144cb8e
2 changed files with 21 additions and 4 deletions

View File

@@ -569,12 +569,21 @@ class mailout_main_ui extends e_admin_ui
else
{
$add = ($pref['mailer']) ? " (".strtoupper($pref['mailer']).")" : ' (PHP)';
$add = ($pref['mailer']) ? " (".strtoupper($pref['mailer']).") " : ' (PHP)';
if($pref['mailer'] == 'smtp')
{
$add .= "Port: ".varset($pref['smtp_port'],25);
$add .= " - ".str_replace("secure=", "", $pref['smtp_options']);
}
$sendto = trim($_POST['testaddress']);
$subjectSitename = ($_POST['testtemplate'] == 'textonly') ? SITENAME : '';
$eml = array(
'e107_header' => USERID,
'subject' => LAN_MAILOUT_113." ".$add,
'subject' => LAN_MAILOUT_113." ".$subjectSitename.$add,
'body' => str_replace("[br]", "\n", LAN_MAILOUT_114),
'template' => vartrue($_POST['testtemplate'],null),
'shortcodes' => $this->getExampleShortcodes(),

View File

@@ -240,13 +240,21 @@ function sendTest()
$mailheader_e107id = USERID;
$pref = e107::pref('core');
$add = ($pref['mailer']) ? " (".strtoupper($pref['mailer']).")" : ' (PHP)';
$add = ($pref['mailer']) ? " (".strtoupper($pref['mailer']).") " : ' (PHP)';
if($pref['mailer'] == 'smtp')
{
$add .= "Port: ".varset($pref['smtp_port'],25);
$add .= " - ".str_replace("secure=", "", $pref['smtp_options']);
}
$sendto = trim($_POST['testaddress']);
$eml = array();
$eml['email_subject'] = LAN_MAILOUT_113." ".SITENAME.$add;
$eml['email_subject'] = LAN_MAILOUT_113." ".$add;
$eml['email_sender_email'] = null;
$eml['email_sender_name'] = null;
$eml['email_replyto'] = null;