Table of Contents
Content Block Plugins
This feature was introduced in VuFind 5.0.
Content blocks are used to embed arbitrary content into templates (currently used primarily for filling in the home pages of various search modules). See the comments in the [HomePage] section of searches.ini for a list of blocks available in your version of VuFind.
Why Use It?
This makes it easy to configure the order and nature of the content displayed to users on search landing pages. You can disable unwanted features or plug in your own through configuration without having to edit core template files.
Key Plugin Details
Default Namespace: \VuFind\ContentBlock
Service Locator Configuration Section in module.config.php: ['vufind']['plugin_managers']['contentblock']
Service Manager Name for Service Locator: VuFind\ContentBlock\PluginManager
Template Name: To display the content, VuFind will attempt to load a template from the ContentBlock folder of the current theme whose name corresponds with the class of the plugin (ignoring the namespace). The template will have access to the variables returned by the plugin's getContext() method.
See the General Plugin Information page for more details on VuFind plugins.
Configuring Content Blocks
Home page content blocks are configured through the [HomePage] content setting in searches.ini for the standard Solr search/home page. Other search types may have recommendation settings in their own .ini files (for example, Summon.ini has its own [HomePage] section).