$rcmail_config['username_domain'] = ''; Enter your domain between the '' and you'll be set. (That's a single quote, not double)
Title: Avoid using @domain.com
Post by: JohnDoh on August 17, 2008, 12:09:51 PM
Look in config/main.inc.php and you will see:
// Automatically add this domain to user names for login // Only for IMAP servers that require full e-mail addresses for login // Specify an array with 'host' => 'domain' values to support multiple hosts $rcmail_config['username_domain'] = '';
If you set this to your domain then it will be automatically added to the end of usernames that don't already have a domain. Something like:
// Automatically add this domain to user names for login // Only for IMAP servers that require full e-mail addresses for login // Specify an array with 'host' => 'domain' values to support multiple hosts $domain_name = $_SERVER['SERVER_NAME']; $domain_name = str_replace('webmail.', '', $domain_name); $rcmail_config['username_domain'] = $domain_name;
is probably what you want or may be try HTTP_HOST instead of SERVER_NAME, I'm not sure which is better. Either way RC will then rewrite the usernames for you.
Title: Avoid using @domain.com
Post by: rknetwork on August 17, 2008, 12:17:51 PM
Thanks, that works perfectly. I also added these lines to \program\include\rcmail_template.inc so users can see their @domain.com after Username field in bold.