Building a form - smbc-digital/form-builder GitHub Wiki
Building a form
This will take you over the basic process of building a form within formbuilder, this will not include more advanced options like Actions/Inbound Values or Payment Calculations.
Base Form
{
"FormName": "Test form",
"BaseURL": "test-form",
"StartPageUrl": "https://www.stockport.gov.uk/start/iag",
"FirstPageSlug": "page-one"
}
This is the start of your form, You are required to have a FormName
, BaseURL
, StartPageUrl
and FirstPageSlug
.
ForName
and StartPageUrl
is used within the header section Header info
BaseURL
refers to the base url within the url example, which users will use to access the form.
The FirstPageSlug
indicates the entry point to the form
https://forms.stockport.gov.uk/BaseURL/FirstPageSlug
A user can navigate to the form via forms.stockport.gov.uk/BaseURL/ without the FirstPageSlug
and with the FirstPageSlug
. Both are valid.
https://forms.stockport.gov.uk/BaseURL/
https://forms.stockport.gov.uk/BaseURL/FirstPageSlug
NOTE: It is recommended to use just the BaseURL
when linking to the form as if the firstpageslug
changes just /BaseURL/ will redirect the user to correct startpage.
Availability
Add basic availability to the form, by default forms are enabled, when developing forms it is recommended to disable the form within stage and production.
Breadcrumbs
Add breadcrumbs for success page and endpoint pages which require them.
Pages
You will now need to define some pages for your form, Pages are placed within the Pages
array.
{
"FormName": "Test form",
"BaseURL": "test-form",
"StartPageUrl": "https://www.stockport.gov.uk/start/iag",
"FirstPageSlug": "page-one",
"Pages": []
}
Success page
The success page is a required page which must be present within the Pages
. It must also have the PageSlug
of success