This tutorial is going to explain how to install the webmail IMAP client Roundcube on shared hosting and then integrate it with the Firefox plugin Webmail Notifier.
Firstly, why the need to install Roundcube in the first place, don’t many hosting companies already provide it built into cPanel? Yes, they do, but the benefit to hosting it yourself is plugins! There are hundreds of plugins that allow you to do pretty much anything. The main reason for me for moving to a self-hosted Roundcube was the plugin Accounts, which allows multiple IMAP accounts from the single interface.
Let’s begin. For the below example, I am going to use the required configuration for Hostgator shared hosting, it maybe different with a different host.
Install Roundcube
Download a copy of Roundcube from roundcube.net, and extract it to the desired location, i.e. mydomain.com/mail (which you could then create a subdomain mail.mydomain.com pointing to it).
In Firefox navigate to mydomain.com/mail/installer for the Roundcube Webmail Installer, click Start Installation and make sure you meet the server environment requirements.
Database setup
Login to cPanel phpMyAdmin and create a new MySQL database called roundcubemail or similar, create a new user and assign it full access privileges to the new database. Fill the Database setup section with user and password details.
IMAP Settings
The IMAP Settings for Hostgator shared hosting are;
default_host – the primary domain name, in my case it is t.info
default_port – remains at port 143
username_domain – this is the IMAP email address, in my case it is [email protected]
SMTP Settings
The SMTP Settings for Hostgator shared hosting are;
smtp_server – mail.mydomain.com, in my case it is mail.t.com
smtp_port – remains at port 25
smtp_user – the IMAP email address, in my case it is [email protected]
smtp_pass – the IMAP email address password
Click create config, then download the two files main.inc.php and db.inc.php and upload them to mydomain.com/mail/config.
Click continue and Test IMAP config to make sure everything is working. Delete the installer folder.
Installing Webmail Notifier Roundcube plugin
Download the Roundcube Plugins pack from MyRoundcube and copy the plugin folder webmail_notifier to mydomain.com/mail/plugins/webmail_notifier. Change the file name of mydomain.com/mail/plugins/webmail_notifier/config.inc.php.dist to config.inc.php.
Edit the file mydomain.com/mail/config/main.inc.php and add webmail_notifier to the list of plugins, similar to;
// List of active plugins (in plugins/ directory) $rcmail_config['plugins'] = array('someotherplugin', 'webmail_notifier');
Login to Roundcube and navigate to the Settings (top right corner), Navigate to section Mailbox View, there will be a new section New Message, download the script from the Get Firefox Webmail Notifier Script download icon.
Installing the Firefox WebMail Notifier plugin
From the same Mailbox View section you can navigate to the Firefox WebMail Notifier plugin page using the Get Firefox Webmail Notifier Addon download icon. Install the plugin and restart Firefox, a grey envelope should appear in the Add-on Bar. Right-click the envelope and select Options, click the Scripts button, then Add and select the localhost.js previously downloaded from the Get Firefox Webmail Notifier Script.
In WebMail Notifier configure a new account, using the localhost script, enter the IMAP details as previously detailed;
Username – this is the IMAP email address, in my case it is [email protected]
Password – this is the IMAP email address passpword
If everything was successful you should now see a Roundcube icon and be notified of all new emails.
Leave a Reply