This module adds a new Element to Acquia Site Studio for Component building. It allows users to select a Webform to embed into a Component. The options are derived from a list of available Webforms.

This does not create Webform Nodes or Webform Blocks and avoids most of the overhead and limitations associated with that. Webforms are lazily loaded into the Site Studio render pipeline to avoid uncacheable penalties normally associated with rendering Webforms inline or to authenticated users.

This module works very similar to Acquia Site Studio Views Element, only for Webform.

How to use

1. Enable Acquia Site Studio and Webform modules.
2. Create a new Acquia Site Studio Component.
3. Add a Webform element to the Layout Canvas.
4. Set a value with any available Webforms.

Dynamically Select Webforms

Optionally, you can add a Select field to the component form builder to
provide a token based value for the component rendering. This allows users to select from any Webform available to display on a page from a single component. Alternatively, you can select 'external data source' and set the path to '/api/cohesion/webform-list'. This requires Site Studio 7.5.0 or higher.

If you would rather use "Options from a custom function" in the Select element of a component form, enter siteStudioWebformElementList as the function name. Then add the token name of this field to the Webform element in the Layout Canvas.

Note that the option list includes all Webforms, even ones not in an 'Open' state, so choose wisely. This is so you could theoretically allow content editing of pages and select Webforms not yet available to the public.

Supporting organizations: 
Supporting Development

Project information

Releases