[imp] get mailserver from login

ke@helinet.de ke@helinet.de
Mon, 10 Jun 2002 16:48:57 +0200



Hi Ed,

> | As we have multiple mailserver with multiple domains and don't want a=
 select 
> | button on the login page, we try to do this: the user gives his full =

> | mail-address as login (user@domain.de) and we get the "true" login (u=
ser)
> | from =

> | the address and the mailserver (mail.domain.de)
> | After reading the mails from Edwin regarding "mail domain", I tried t=
o invoke
> | =

> | vinfo (with some changes) and changed my servers.php:
> | =

> | $servers['imap2'] = array(
> |     'name' => $vdomain,
> |     'server' => 'mail.'.$vdomain,
> |     'protocol' => 'imap',
> |     'port' => 143,
> |     'folders' => '',
> |     'namespace' => '',
> |     'maildomain' => $vdomain,
> |     'smtphost' => 'localhost',
> |     'realm' => '',
> |     'preferred' => ''
> | );
> | =

> | The problems seems to be to get the $vdomain in servers.php. I sugges=
ted, 
> | something like
> | ($user,$vdomain)= split ("\@",$imp['user']);
> | would do the job, but this is wrong. Does anyone know, how to get the=
 domain 
> | from the login-page in servers.php?
> =

> Kerstin,
> =

> I do it this way.
>   =

this does not help at my side, as I don't have virtual domains on my 
webserver. I really have different mailserver on (sometimes, not always) 
different machines. That's why I would like the customer to type in 
login@domain and not only login.
I hope, I don't have to patch the code, as I don't have much experience with 
php.

Regards, Kerstin