Author Topic: SMTP with Multiple Domains and t-online.de  (Read 4533 times)

Offline jolic

  • Jr. Member
  • **
  • Posts: 24
SMTP with Multiple Domains and t-online.de
« on: December 06, 2013, 05:24:25 AM »
Hello,

I currently use RC 0.9.5 with multiple server domains as a choice and unfortunately can only specify one SMTP server because this is not possible in an array.

Here a part from my main.inc.php:
Code: [Select]
// Array IMAP Server:
$rcmail_config['default_host'] = array (
  'ssl://imap.web.de:993' => 'WEB.de (SSL)',
  'ssl://imap.gmail.com:993' => 'GMail (SSL)',
  'ssl://secureimap.t-online.de:993' => 'T-Online (only read!)'
);


// %z - IMAP domain (IMAP hostname without the first part)
$rcmail_config['smtp_server'] = 'tls://smtp.%z:587';
// this does not work with the domain t-online.de, because smtp is called with 'securesmtp' instead of 'smtp'

Maybe anyone have a solution or idea about this?


btw: I try this, but it does not work unfortunately, as %z isn't a variable ;-(
Code: [Select]
if ('%z' == 't-online.de' )
 {
  $rcmail_config['smtp_server'] = 'tls://securesmtp.%z:587';
 }
else
 {
  $rcmail_config['smtp_server'] = 'tls://smtp.%z:587';
 }

Here is my (quick'n'dirty) solution to this issue and sorry for the twin post  :-\
(I check the variable $z in rcube_utils.php)


« Last Edit: December 09, 2013, 03:20:30 PM by jolic »