adding info about display_message.php
[squirrelmail.git] / doc / plugin.txt
index 2560b3088e0aa4b3f92e302d6961c1b447712b5f..5aa907a8c074a0fbb3659a9730cef999e5a4a35c 100644 (file)
@@ -188,6 +188,8 @@ version is not listed, files are included from v.1.3.2.):
       9.2. $prefs_backend (from 1.4.3rc1 and 1.5.0)
            functions/db_prefs.php
            functions/file_prefs.php
+         9.2.1. functions/display_messages.php 
+                (loaded only by file_prefs.php)
 
 Hook Types:  Parameters and Return Values
 -----------------------------------------
@@ -471,7 +473,10 @@ This is a breakdown of the data passed in the array to the hook that is called:
 To set up links for actions, you assign them like this:
 
   $Args[1]['<plugin_name>']['href'] = 'URL to link to';
-  $Args[1]['<plugin_name>']['text'] = 'What to display';
+  $Args[1]['<plugin_name>']['text'] = _("What to display");
+
+Note: _("What to display") is explained in the section about
+internationalization.
 
 It's also possible to specify a hook as "attachment type0/*",
 for example "attachment text/*". This hook will be executed whenever there's
@@ -495,7 +500,7 @@ display a custom link:
       $Args[1]['demo']['href'] = SM_PATH . 'plugins/demo/zip_handler.php?'
          . 'passed_id=' . $Args[3] . '&mailbox=' . $Args[4]
          . '&passed_ent_id=' . $Args[5];
-      $Args[1]['demo']['text'] = 'show zip contents';
+      $Args[1]['demo']['text'] = _("Show zip contents");
    }
 
 The file plugins/demo/zip_handler.php can now do whatever it needs with the
@@ -684,6 +689,9 @@ for you.  This is the preferred method of building options lists going forward.
                         or other code to the user input
          post_script    You may specify some script (usually Javascript) that
                         will be placed after (outside of) the INPUT tag.
+         htmlencoded    disables html sanitizing. WARNING - don't use it, if user
+                        input is possible in option or use own sanitizing functions.
+                        Currently works only with SMOPT_TYPE_STRLIST.
 
       Note that you do not have to create a whole new section on the options
       page if you merely want to add a simple input item or two to an options