Roundcube Community Forum

 

Little tip (or mistake?) for not entering domain names

Started by nabab, February 12, 2010, 06:27:50 AM

Previous topic - Next topic

nabab

Hi,

I thought I'd post it here in case someone has the same problem than I had.

If you have installed roundcube on a server with several domains and all domains can access it through an aliased subdomain like webmail.mydomain.net (or whatever subdomain name)

e.g. in Apache:
ServerName webmail
ServerAlias webmail.*

And that you don't want your IMAP users to enter their domain name each time, you can put this line in the main.inc.php:
$rcmail_config['username_domain'] = substr($_SERVER['HTTP_HOST'],strpos($_SERVER['HTTP_HOST'],'.')+1);
and your user can just enter his/her username without @mydomain.net

Couldn't figure out a configuration parameter allowing me to do this... Is there?

Thanks,

Thomas