[imp] VPOPMAIL + IMP + DOMAINS
Atif Ghaffar
aghaffar@developer.ch
Sun, 28 Jan 2001 23:17:49 +0100
Hi jose.
This is a quiet common scenario in web hosting companies.
here is what you should do.
In your apache's httpd.conf
make sure you have
UseCanonicalName Off
then define a Virtualhost as usual with a ServerAlias mail.*
Example
<VirtualHost 193.247.80.43>
ServerName mail.4unet.net
ServerAlias mail.*
DocumentRoot /ispman/4unet.net/vhosts/mail/htdocs/horde/imp
CustomLog /var/log/httpd/vhosts/mail.4unet.net.access
combined
ErrorLog /var/log/httpd/vhosts/mail.4unet.net.errors
DirectoryIndex index.php3 index.html
Alias /horde/ /ispman/4unet.net/vhosts/mail/htdocs/horde/
Alias /imp/ /ispman/4unet.net/vhosts/mail/htdocs/horde/imp/
php3_include_path .:/ispman/4unet.net/vhosts/mail/htdocs/php
php3_auto_prepend_file
/ispman/4unet.net/vhosts/mail/htdocs/php/prepend.php3
php3_magic_quotes_gpc Off
php3_magic_quotes_runtime Off
</VirtualHost>
in your defaults.php3 set the following.
$default->from_server = preg_replace("/(\w+)\.([\w\-]+)\.(\w+)\:*.*/",
"\\2.\\3", $HTTP_SERVER_VARS['SERVER_NAME']);
Add these lines in mailbox.php3 somewhere after all including of files
is done.
look for require './config/mime.php3'; and add the following after that.
if ($HTTP_POST_VARS['imapuser'] && (!ereg($default->from_server,
$HTTP_POST_VARS['imapuser']))){
$HTTP_POST_VARS['imapuser']=$HTTP_POST_VARS['imapuser'] . '@'.
$default->from_server;
$imapuser=$HTTP_POST_VARS['imapuser'];
}
Voilla.
you should be all set.
If you have problems, let me know.
"Jose P. E. Junior" wrote:
>
> Well people...
>
> I just ended a fresh instalation of IMP/HORDE (imp 2.2.3, horde 1.2.3), now
> I'm thinking in some alterations, but I need some help:
>
> I run a web hosting service, I want to put IMP as my webmail for people
> that have a domain with me, so, I'm thinking in something like this
>
> example.com is the domain of my client.
>
> webmail.example.com
>
> redirects him to the imp page, he just need to put his login and password
> and voila!
>
> But...
>
> I use qmail/vpopmail, i can login in the pop server as client@example.com,
> then he'll get the mail for that user and that domain.
>
> I need to discover a way to pass to imp these variables (via url, or a php
> page), like
>
> login.php3?domain=example.com
>
> and with a additional problem, i don't want to show a server list to my
> client, but it seens to be the oly way to get IMP working with pop servers!
>
> Thanks for any help
>
> --
> Jose P. E. Junior - ICQ 1142954
> Network Admin - Geo-rede Wireless Internet
> http://www.geo-rede.com.br
>
> --
> IMP mailing list: http://horde.org/imp/
> Frequently Asked Questions: http://horde.org/faq/
> To unsubscribe, mail: imp-unsubscribe@lists.horde.org
--
Atif Ghaffar
Internet Development Manager
4unet AG/SA
-------------------------.
+41 78 787 51 45 ¦ voice
+41 24 441 09 03 ¦ fax
http://www.4unet.net ¦ www
http://atif.developer.ch ¦ homepage
atif.ghaffar@4unet.net ¦ email
Do you speak Unix?