Poll Plugin Developer Guide - Component Instantiation

Instantiating a Poll Component

Instantiate a poll component directly when you need to provide a fixed website layout for webmasters, instead of using the Channel Editor component catalog.

To create a poll component, use the CMS Console. Go to /hst:[your project]/hst:configurations/[your project]/hst:pages and define the page layout by creating a structure of hst:components. You can nest components as needed. Use the hst:referencecomponent attribute to apply inheritance where applicable. The poll component should be referenced by a leaf component in this structure.

Configure the following attributes on the component that represents the poll:

AttributeValue
hst:componentclassnameSpecify the class name of your custom poll component, or use org.onehippo.forge.poll.component.PollComponent to use the default component provided by the plugin.
hst:templateEnter the name of your rendering template, or use poll.component.ftl to apply the default rendering from the plugin.
hst:parameternamesList the component's parameter names as a multi-value attribute. For details on available parameters, see Poll Component Parameters.
hst:parametervaluesProvide the parameter values as a multi-value attribute. The order of values must match the order of the parameter names.
Share Feedback
Page: /build/plugins/poll/component-instantiation
Section: Build
Category *