Description
Allows you to execute plugins per name or the set of plugins for a given flavor from your templates.
Availabilty
Available as of blojsom 2.24.
Installation and Setup
In your global /WEB-INF/plugin.properties file, add the following line:
plugin-helper=org.blojsom.plugin.helper.PluginHelperPlugin
You may then add "plugin-helper" to one of the flavor-based plugin chains. These plugin chains can be found in the individual blog's plugin.properties file. For example:
html.blojsom-plugin-chain=..., plugin-helper
Usage and URL Parameters
You can then use the following plugin helper methods in your template:
$BLOJSOM_PLUGIN_PLUGIN_HELPER.processEntryForPlugin(BlogEntry entry, String pluginName)
$BLOJSOM_PLUGIN_PLUGIN_HELPER.processEntryForFlavor(BlogEntry entry, String flavor)
$BLOJSOM_PLUGIN_PLUGIN_HELPER.processEntriesForPlugin(BlogEntry[] entries, String pluginName)
$BLOJSOM_PLUGIN_PLUGIN_HELPER.processEntriesForFlavor(BlogEntry[] entries, String flavor)
Context Attributes and Types
The following table describes the context attributes that are available and their associated type.
| Context key |
Input or Output |
Type |
Description |
| BLOJSOM_PLUGIN_PLUGIN_HELPER |
Input |
org.blojsom.plugin.helper.PluginHelperPlugin.PluginHelper |
Various methods on this object exist to execute a plugin or the plugins for a specific flavor for a given entry or array of entries. |