Webform

This is a paragraph type used for embedding webforms within content. It allows you to add existing webforms to a page.

Prerequisites

  • You must have already created your webform using the Webform module before embedding it. This paragraph type does not create a new webform.
  • Consider reviewing the Drupal Webform Tutorials (by Jacob Rockowitz) for comprehensive guidance on creating and managing webforms.

How to Use the Webform Paragraph

  1. Add the Webform Paragraph: Select “Webform” from the available paragraph types when editing a content item.

  2. Select the Webform: Choose the desired webform from the “Embedded Webform” field. This field displays a list of available webforms created using the Webform module.

    Webform paragraph admin fields

  3. Configure Webform Status: Use the “Webform status” field to control the webform’s availability:

    • Open: Allows users to submit the webform.
    • Closed: Prevents new submissions. Existing submissions remain accessible.
    • Scheduled: Set open and close dates for the webform.
  4. Default Webform Submission Data (Optional): The “Default webform submission data (YAML)” field allows you to pre-populate webform fields with default values.

    • Enter YAML code to define the default values.
    • This is useful for providing guidance or setting common values for users.
    • Consult the YAML specification for correct syntax.

Fields

NameMachine nameRequiredDescription
Embedded Webformfield_prgf_webformNoWebform entity reference field. Select the webform you want to embed.
Default webform submission data (YAML)field_prgf_webform_default_dataNoYAML code to pre-populate webform fields with default values.
Webform statusfield_prgf_webform_statusNoControls the availability of the webform. Options: Open, Closed, or Scheduled.

Content Types That Support Webform

Last modified March 11, 2025: feat: improve docs (3e852052)