Configuration 

Site settings 

The following settings are exposed through the site set and can be overridden per site.

Name Type Default
string Form

handlebars_forms.view.templateName

handlebars_forms.view.templateName
Type
string
Default
Form

Name of the Handlebars template used for rendering a form when no per-form template is configured. Corresponds to a template file in the configured Handlebars template root paths, e.g. Form.hbs.

TypoScript 

The site set sets up a TypoScript object at plugin.tx_form.handlebarsForms, where integrators define how each form is rendered. The structure is:

plugin.tx_form.handlebarsForms {
    # Applied to every form (fallback)
    default {
        templateName = {$handlebars_forms.view.templateName}

        dataProcessing {
            10 = process-form
            10 {
                # ... HBS_* configuration
            }
        }
    }

    # Override for a specific form – merged on top of "default"
    my_contact_form {
        templateName = ContactForm
    }
}
Copied!

When a form is rendered, the extension looks up configuration blocks in the following order. All matching blocks are merged, with later entries winning:

  1. default – applied to every form
  2. Form unique identifier (e.g. my-contact-form-123)
  3. Original form identifier before suffixes are appended (e.g. my-contact-form)
  4. Form persistence identifier (the YAML file path, e.g. EXT:my_extension/Resources/Private/Forms/ContactForm.form.yaml)

The templateName key names the Handlebars template file (without extension) that receives the data produced by the process-form processor as its template context.

See Conditions in the processor reference for details on using if to conditionally omit keys from the output.