PLG getplugin getConfigTooltip

From GeeklogWiki
Revision as of 17:18, 10 April 2011 by Tom (talk | contribs) (New page: As of 1.8.0 Geeklog's Configuration offers support for tooltips for configuration options. The following plugin API function provides this information: <pre>function PLG_getConfigTooltip(...)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

As of 1.8.0 Geeklog's Configuration offers support for tooltips for configuration options. The following plugin API function provides this information:

function PLG_getConfigTooltip($group, $id)

Where $group is the internal name of the plugin (e.g. 'spamx') and $id is the name of the configuration option being requested.

On the plugin side, this would be implemented as

function plugin_getconfigtooltip_foo($file)

Conventions

  • If the function does not exist the Configuration will fall back and use the documentation URL from plugin_getdocumentationurl_foo.
  • If the function returns a NULL then a tooltip will be displayed based on information found in the document provided by plugin_getdocumentationurl_foo. This document needs to be formatted similar to Geeklog's documentation in order for it to work.
  • If text is returned for a given $id then Geeklog's own tooltip system will be used.
  • If a blank string returned then no tooltip will be displayed and if a URL is returned from plugin_getdocumentationurl_foo that will be used instead.