Input control block types

Forms are built by adding blocks for the form inputs to a page. These blocks can be added directly to the page or using stacks, containers and layouts. A Submit Button block submits the form and configures processing of the form.

Address Lookup Input

Address Lookup input for Form Reform.

Start entering an address or postal code and be presented with matching addresses. When an address is selected, the address data can also be cross-populated to associated form controls such as latitude, longitude, address1, address2, state, country etc.. The Google Places API must be enabled on your google maps API account.

Detailed data from the address lookup will also be returned in a hidden field as JSON. This data will be available to the processing pipeline as {{place.holders}} using dot.notation to index into the data. When not provided, fallback actions may attempt to partially fill the data bay parsing the entered text.

A map of address lookup data to other form input fields can be configured to automatically populate further fields in the form. Any specific address will resolve to a subset of these fields. Accuracy and provision depends on data from Google.
  • Street Number [street_number]
  • Route / Road [route]
  • Address 1 [address1]
  • Address 2 [address2]
  • Town / City [town]
  • State code [sc]
  • State [state]
  • Postal code / Zip [postal_code]
  • Postal code prefix [postal_code_prefix]
  • Postal code suffix [postal_code_suffix]
  • Country code [cc]
  • Country [country]
  • Latitude [latitude]
  • Longitude [longitude]
  • Formatted Addr [formatted]
This block may be used in repeatable groups

Options Attribute Checkbox List Input

Checkbox list from Options Attribute values for Form Reform.

Configure a checkbox list to choose from and provide values suitable for saving to an options attribute. Allows the initially selected option to be set.
This block may be used in repeatable groups

Options Attribute Radioset Input

Radioset from Options Attribute values for Form Reform.

Configure a radioset to choose from and provide values suitable for saving to an options attribute. Allows the initially selected option to be set.
This block may be used in repeatable groups

Options Attribute Select Input

Dropdown select from Options Attribute values for Form Reform.

Configure a select list to choose from and provide values suitable for saving to an options attribute. Allows the initially selected option to be set.
This block may be used in repeatable groups

Checkbox Input

Checkbox input for Form Reform.

Initial state and required state are configurable. For Bootstrap5 based themes, an option allows rendering as a switch.
This block may be used in repeatable groups

Checkbox List Input

Checkbox List input for Form Reform. The default view is for Bootstrap5. Set the bootstrap3_elemental or a custom template for other themes.

Configure a list of checkbox values and labels. Options allow initial checked state to be set. An option allows the list to be shown vertically or horizontally. Checkbox lists vary between themes, so the default block template is designed for Bootstrap5 and we have a separate template for Bootstrap3. For other theme frameworks you may need to create a custom template with appropriate classes. Specific to Bootstrap5 is an option to show the items as switches instead of as checkboxes.
This block may be used in repeatable groups

Checkbox List Combi Input

Checkbox List Combi input for Form Reform. The default view is for Bootstrap5. Set the bootstrap3_elemental or a custom template for other themes.

Configure a list of checkbox input values and labels with an other label which opens a text box. Options allow the initial checked items to be set. An option allows the list to be shown vertically or horizontally. Checkbox lists vary between themes, so the default block template is designed for Bootstrap5 and we have a separate template for Bootstrap3. For other theme frameworks you may need to create a custom template with appropriate classes.
This block may be used in repeatable groups

Checkbox Matrix Input

Checkbox Matrix input for Form Reform. Build a table of checkbox inputs.

Configure a column list of checkbox input values and labels and a row list of row labels. The columns and rows are then combined into a table of checkbox input groups, one group for each column.
This block may be used in repeatable groups

Checkbox + Message Input

Checkbox input with associated rich text message for Form Reform.

Display a checkbox with a rich text message alongside. This can be useful for requiring a user to grant a permission where a complex message about things like privacy or terms with links need to be associated. Initial state and required state are configurable. For Bootstrap5 based themes, an option allows rendering as a switch.
This block may be used in repeatable groups

Color Picker Input

Color picker input for Form Reform.

Color format, initial value and many picker options are configurable.
This block may be used in repeatable groups

Continent Input

Continent input for Form Reform.

Configure a list of continents to select from. Options allow the initially selected continent to be by geolocation or to a default continent.

An Attach After Submit block template can be used with the Geolocation option to render nothing to the form and attach a geolocated continent after the form is submitted.
This block may be used in repeatable groups

Country Input

Country input for Form Reform.

Configure a list of countries to select from. Options allow the initially selected country to be by geolocation or to a default country.

An Attach After Submit block template can be used with the Geolocation option to render nothing to the form and attach a geolocated country after the form is submitted.
This block may be used in repeatable groups

Country State Input

Country State input for Form Reform.

Configure a list of countries to select country and state from. Options allow the initially selected country to be by geolocation or to a default country.

An Attach After Submit block template can be used with the Geolocation option to render nothing to the form and attach a geolocated country and state/province after the form is submitted.
This block may be used in repeatable groups

Custom Text Input

Text input with custom validation for Form Reform

Define a regular expression and/or your own validation function to restrict input to a specific format.

An optional regular expression will be applied in the browser to restrict the entered text and after form submission to validate text on the server. The regular expression will be automatically wrapped in /^ ... $/ where necessary for evaluation. The regular expression must be valid for both JavaScript and PHP.

Optional further validation after submission can be specified by providing the name of a validation class. The validation class should provide a method class_name->validate($text) which returns true/false. For testing, the class JtF\FormReform\Examples\CustomValidate will fail any text containing X.

Minimum and maximum input lengths are also configurable.
This block may be used in repeatable groups

Date Input

Date input for Form Reform.

Minimum and maximum dates are configurable.
This block may be used in repeatable groups

DateTime Input

DateTime input for Form Reform.

Minimum and maximum dates/times are configurable.
This block may be used in repeatable groups

Email Input

Email input for Form Reform.

Options set strength of validation and for checking against an MX record.
This block may be used in repeatable groups

Email Confirm Input

Email Confirm input for Form Reform. Two email inputs are validated to match.

Options set strength of validation and for checking against an MX record.
This block may be used in repeatable groups

Grouped Select Input

Select input for Form Reform with groups of options.

Configure a list of select values and labels divided into groups. Options allow the initially selected option to be set.
This block may be used in repeatable groups

Handle Input

Handle input for Form Reform.

Restrict input to lowercase_decimal_and_underscore_handle. Minimum and maximum input lengths are configurable.
This block may be used in repeatable groups

Handle with Dot Input

Handle with dots input for Form Reform.

Restrict input to lowercase_decimal_and_underscore_handle with "." dots allowed. Minimum and maximum input lengths are configurable.
This block may be used in repeatable groups

Hidden Input

Hidden input for Form Reform.

An Attach After Submit block template can be used to render nothing to the form and attach the data after the form is submitted. This provides a secure option for some types of fixed data, but cannot be used to maintain data from previous form inputs
This block may be used in repeatable groups

Latitude / Longitude Input

Latitude or Longitude input for Form Reform.

Configure a pair of these inputs, one for latitude and one for longitude. Minimum, maximum and step values are configurable within the limits of latitude or longitude. This facilitates flexible layout of the latitude/longitude inputs.
This block may be used in repeatable groups

Like Input

Like input for Form Reform.

Register a like by clicking an icon. Icons and icon colours are configurable. Behind the scenes this is a checkbox.
This block may be used in repeatable groups

Lowercase Input

Lowercase input for Form Reform.

Restrict input to lowercase text. Minimum and maximum input lengths are configurable.
This block may be used in repeatable groups

Masked Text Input

Masked Text input for Form Reform.

Define a mask to restrict inputs to a specific format

Mask formatting characters:
  • 9 - A decimal digit
  • A - An letter
  • * - A letter or decimal digit
Any other character will be inserted directly in the text. Alphanumeric characters in the mask may cause issues.

Format characters other than the mask character will be included with the form field in the processing pipeline. Unmasked data is provided as the Input Name suffixed "_unmasked".

Minimum and maximum input lengths are also configurable. When specified, the maximum length must include the placeholder characters in the mask.
This block may be used in repeatable groups

Number Input

Number input for Form Reform.

Minimum, maximum and step values are configurable.
This block may be used in repeatable groups

Numeric Digits Input

Numeric digits input for Form Reform.

Restrict input to numeric digits. Minimum and maximum input lengths are configurable. Note: this is not the same as a number input!
This block may be used in repeatable groups

Password Input

Password input for Form Reform. For entering a password. Use "Password Confirm" for setting a password.

Minimum and maximum password lengths are configurable. Password inputs are not saved with form data. If you use a password input, you also need to implement a handler that uses that input for whatever you are applying a password to.
This block may be used in repeatable groups

Password Confirm Input

Password Confirm input for Form Reform. Two passwords are validated to match.

Minimum and maximum password lengths are configurable. Password inputs are not saved with form data. If you use a password input, you also need to implement a handler that uses that input for whatever you are applying a password to.
This block may be used in repeatable groups

Radio Matrix Input

Radio Matrix input for Form Reform. Build a table of radio options.

Configure a column list of radio input values and labels and a row list of row labels. The columns and rows are then combined into a table of radio input groups, one group for each column.
This block may be used in repeatable groups

Radioset Input

Radioset input for Form Reform. The default view is for Bootstrap5. Set the bootstrap3_elemental or a custom template for other themes.

Configure a list of radio input values and labels. Options allow the initial selected item to be set. An option allows the list to be shown vertically or horizontally. Radioset lists vary between themes, so the default block template is designed for Bootstrap5 and we have a separate template for Bootstrap3. For other theme frameworks you may need to create a custom template with appropriate classes.
This block may be used in repeatable groups

Radioset Combi Input

Radioset Combi input for Form Reform. The default view is for Bootstrap5. Set the bootstrap3_elemental or a custom template for other themes.

Configure a list of radio input values and labels with an other label which opens a text box. Options allow the initial selected item to be set. An option allows the list to be shown vertically or horizontally. Radioset lists vary between themes, so the default block template is designed for Bootstrap5 and we have a separate template for Bootstrap3. For other theme frameworks you may need to create a custom template with appropriate classes.
This block may be used in repeatable groups

Range Input

Range input for Form Reform.

For restricted ranges of numbers to show in a range slider. Minimum, maximum and step values are configurable.
This block may be used in repeatable groups

Rating Input

Rating input for Form Reform.

Rate by selecting from a list of icons from zero to a maximum (default 0 to 5 stars). Minimum, maximum, icons and icon colours are configurable. Rating values are stored as floating point decimals from 0 to 1. Behind the scenes this is a radioset.
This block may be used in repeatable groups

Rich Text Input

Rich text input for Form Reform.

Minimum and maximum input lengths are configurable.

Whilst the rich text editor has many options, you should keep the edit controls presented to your visitors to the minimum necessary for your forms. This form control is not a word processor. Allowing images, links, tables, fonts etc. will require you to work out how these options integrate with your theme. Use of such options is not supported with Form Reform.
This block cannot be used inside repeatable groups

Select Input

Select input for Form Reform.

Configure a list of select values and labels. Options allow the initially selected option to be set.
This block may be used in repeatable groups

Select Combi Input

Select Combi input for Form Reform.

Configure a list of select values and labels with an other label which opens a text box. Options allow the initially selected option to be set.
This block may be used in repeatable groups

Signature Input

Signature input for Form Reform.

The user can draw a signature with their mouse or touch device. This is saved with the form data as a base64 encoded image.

Whilst the the Initial Value can be set to persist a previously entered signature, for security we recommend a signature is not persisted beyond the current form submission.

When persisted a signature may not be edited, but may be cleared and re-entered if a clear button is enabled.

The signature may be saved as base64 data with the form submission. Form save handlers may be configured to redact the signature field from form data. The signature image is not added as an image in the file manager.

To use a signature, such as in an email or message, insert an html image <img src="{{form:my_signature_field}}">.
This block cannot be used inside repeatable groups

State Input

State select input for Form Reform.

Configure a list of States to select from. Options allow the initially selected state to be by geolocation or to a default state.

An Attach After Submit block template can be used with the Geolocation option to render nothing to the form and attach a geolocated state after the form is submitted.
This block may be used in repeatable groups

Telephone Number Input

Telephone Number input for Form Reform.

Minimum and maximum input lengths are configurable.
This block may be used in repeatable groups

Text Input

Text input for Form Reform.

Minimum and maximum input lengths are configurable.
This block may be used in repeatable groups

Text Confirm Input

Text Confirm input for Form Reform. Two inputs are validated to match.

Minimum and maximum input lengths are configurable.
This block may be used in repeatable groups

Text Area Input

Text Area input for Form Reform.

Minimum and maximum input lengths are configurable.
This block may be used in repeatable groups

Time Input

Time input for Form Reform.

Minimum and maximum times are configurable.
This block may be used in repeatable groups

Up Down Vote Input

Up Down Vote input for Form Reform.

Register an up or down vote by clicking an icon. Icons and icon colours are configurable. Behind the scenes this is a radioset.
This block may be used in repeatable groups

Uppercase Input

Uppercase input for Form Reform.

Restrict input to UPPERCASE TEXT. Minimum and maximum input lengths are configurable.
This block may be used in repeatable groups

Url Input

Url input for Form Reform.

Options add a ping to validate the actual URL.
This block may be used in repeatable groups

Special purpose block types


Captcha

Captcha for Form Reform.

The captcha block inserts a captcha as configured through Captcha Setup and validates that captcha when the form is submitted.
This block cannot be used inside repeatable groups

CCM Token

CCM Token spam and CSRF trap for Form Reform.

A security token to validate the page a form is associated with. Tokens are valid for 24 hours, hence this block should not be used on forms/pages that are cached for longer than 24 hours.
This block cannot be used inside repeatable groups

Geofence Continent

Geofence Continent for Form Reform.

Visitors are geolocated by IP address and any not matching the continent location rules will fail validation. Options allow matching for inclusion/exclusion, exempting administrators, considering a failed check as spam and redirect on page load.

In the Redirect tab:
  • When Stay on this page is selected, the geofence will be checked when the form is submitted.
  • When Redirect is selected, the geofence will be checked when the page is loaded. Any geofence based redirect will be made immediately and a redirected visitor will not be given any chance to use the form.
Do not rely on this as a sole spam check. IP addresses and hence geolocation can be forged.
This block cannot be used inside repeatable groups

Geofence Country

Geofence Country for Form Reform.

Visitors are geolocated by IP address and not matching the country location rules will fail validation. Options allow matching for inclusion/exclusion, exempting administrators, considering a failed check as spam and redirect on page load.

In the Redirect tab:
  • When Stay on this page is selected, the geofence will be checked when the form is submitted.
  • When Redirect is selected, the geofence will be checked when the page is loaded. Any geofence based redirect will be made immediately and a redirected visitor will not be given any chance to use the form.
Do not rely on this as a sole spam check. IP addresses and hence geolocation can be forged.
This block cannot be used inside repeatable groups

Honeypot

Honeypot spam trap for Form Reform.

Just leave it there and the dumb spammers will show themselves by trying to fill it in.
This block may be used in repeatable groups

Message Display

Display a Form Reform response message.

Messages are generated by the submit handling pipeline. This block is a placeholder for displaying those messages following submission of a form.
This block cannot be used inside repeatable groups

Prohibit Repeated Form

Prevent form from being entered if it has already been submitted.

Checks one or more form stores for completion of the form by name, page, store and time. If the form has already been completed, a message is shown and an optional redirect made. Any check that redirects will skip further checks. For multiple checks, multiple instances of this block can be added to the page. Users with edit permission are never redirected.
This block cannot be used inside repeatable groups

Repeatable Group

Repeatable group control for Form Reform.

Provides an in-page toolbar for a repeatable group. A repeatable group can to use a container, layout, stack or any other grouping of input blocks as a repeatable group of inputs and manage the repetition of that group.
This block may be used in repeatable groups

Require Form

Require another form/page to be completed before this form can be shown.

Checks one or more form stores for completion of another form by name, page, store and time. If the other form has not completed, a message shown and an optional redirect made to the other form page. Any check that redirects will skip further checks. For multiple checks, multiple instances of this block can be added to the page. Users with edit permission are never redirected.
This block cannot be used inside repeatable groups

Spinner

A spinner to show while a form is submitting.

The spinner can be configured to overlay the whole page or only the form or only the form control. Alternative spinners are available as block templates.
This block cannot be used inside repeatable groups

Submit Button

Submit a form created with Form Reform and manage the submit handling.

The Submit Button submits a form with all user-entered data from the form input blocks and manages the processing of that data by configuring a pipeline of Form Handlers.
This block cannot be used inside repeatable groups

Text Suggestions

Attach a list of suggestions to a text input.

The list of suggestions will then be offered for the attached text input. When Suggestions are attached to a control repeated in a group this block could be placed inside a repeatable group, but it is better to place it outside the group - it will still attach to all repetitions of an input.
This block may be used in repeatable groups