[RCD] Hooks

Thomas Bruederli thomas at roundcube.net
Sat Jan 2 13:32:45 CET 2016

On Mon, Nov 16, 2015 at 2:17 PM, Владимир Горпенко <vgo at stels.ru> wrote:
> Hello!
> 1. Is there any more recent information about hooks than
> http://trac.roundcube.net/wiki/Plugin_Hooks?

I'm afraid the documentation on the wiki lags a little behind our
codebase. Sorry for that!
We'll try to keep up with it in the future. Of course your
contributions are welcome ;-)
> In particular, I found the following hooks are not mentioned in this source:
> acl_rights_simple
> acl_rights_supported
> db_table_name
> error_page
> folder_create
> folder_delete
> folder_form
> folder_rename
> folder_update
> imap_init
> imap_search_before
> keep_alive
> managesieve_connect
> message_saved
> message_send_error
> password_change
> password_ldap_bind
> preferences_section_header
> secure_token
> template_object_$object
> unauthenticated
> user_delete
> user_delete_commit
> user_delete_prepare
> user_delete_rollback

Many of them come from plugins (acl, manasieve, password) and those
are not documented in the wiki.
> 2. What are the hooks can be used to completely replace the text and
> structure of the message for reading and quoting for a response?

'message_part_structure' and 'message_load' for reading messages,
'message_compose_body', 'message_ready' and 'message_before_send' for
composing messages.

You should look at the enigma plugin to see an example for interacting
with the message structure:

Please note that the 'message_ready' hook was added in 1.2-beta and is
not available in older versions.


More information about the dev mailing list