Plugins Installation


Installing and Registering plugins in Roundcube webmail



How to register a plugin

Before attempting to register plugins in Roundcube Webmail, you should pay close attention to the specifics of the plugin in question. For example, plugins such as calendar, sticky_notes and many others require you to add or modify tables in roundcube’s database.

Irrespective the source of your plugin, chances are that the developer has included important documentation and requirements you should read before attempting to use the plugin. Please, do so. Take a few moments to read and get familiar with the plugin you will be working with even if you have no PHP knowledge. It will save you a lot of time and most likely you will effectively configure, register and use those plugins without going into bumps or opss!

Once you have a general idea of the plugin you are working with, it is time not to register it but to configure it. Hence, you want to keep reading below.

Configuring Plugins


    • To configure a plugin, make a copy of its config.inc.php.dist file in its same directory and rename the new file to config.inc.php
Always keep the source file config.inc.php.dist in its directory. Do not delete or rename this file.
  • You should now have a new file in your plugin’s folder ./plugins/plugin_sample1/config.inc.php
  • Leave the config.inc.php.dist file in the plugin directory. Do not remove or rename this file.
  • Open the new config.inc.php file and edit settings according to your needs.
If the plugin has a SQL folder, run the included database script against your roundcube database to setup a new database table or to adjust an existing one respectively. You may not have to run the sql script if the plugin being installed offers database versioning support (all MyRoundcube plugins for Roundcube Webmail 0.9.x and newer offer database versioning support).
Requirements and Dependencies

  • In almost every plugin, special requirements or dependencies are mentioned at the top of the main plugin script. In the case of MyRoundcube plugins, this important information is also displayed in Plugin Manager Center.
  • The main plugin script is located at ./plugins/plugin_sample1/plugin_sample1.php.

Bravo! Now we know and have a basic understanding about how to configure a plugin. Next, it is time to register the plugin because we have already configured it! So how do we proceed? …keep on reading.


Registering Plugins


To register a plugin you have previously configured, edit ./config/config.inc.php (Roundcube 1.0.x or newer) or ./config/main.inc.php on earlier versions. Find the following section in the configuration file:

...
// List of active plugins (in plugins/ directory)
$rcmail_config['plugins'] = array();
...

The code section above is the configuration array where you register plugins in your Roundcube installation. For examplr, to enable (register) plugin_sample1 and plugin_sample2 simply add them to your configuration as follow:

...
// List of active plugins (in plugins/ directory)
$rcmail_config['plugins'] = array('plugin_sample1', 'plugin_sample2');
...

Congratulations! You have now configured and registered your plugins. Time for testing… browse to your Roundcube Webmail installation and explore its new features. Have fun.