Data privacy notice

 

When this content is loaded, usage information is transmitted to Vimeo and may be processed there.

 

             

URL parameters

Modified on Mon, 22 Apr at 1:11 PM

When you open a form, you can add additional parameters to the URL of the form to prefill some form fields. You need to separate URL parameters from the main URL by adding a question mark ?. If you need multiple parameters, separate them with an ampersand &. This results the following pattern for the URL:

http://<host>//formcycle/form/alias/1/demo?<field1Name>=<field1Value>&<field2Name>=<field2Value>&...

Please note that when you need to use special characters, you need to escape them. For example, to specify an URL parameters named tfCompany with the value Clark & Joe Ltd.:

http://<host>//formcycle/form/alias/1/demo?tfCompany=Clark%20%26%20Joe%20Ltd.


Using URL parameters

You can use URL parameters to prefill form fields both when the form is opened for the first time as well as when a saved or submitted form is opened again. Please note that existing form field values are overwritten when URL parameters are used.


Examples

Prefilling an input field

Setup in the FORMCYCLE Designer for prefilling an input field.

When opening the form, we set the URL parameter tfMail. This sets the initial value of the corresponding input field.

Create a input field with the name tfMail. When you open the form, add the URL parameter tfMail and set it to an email address. The URL could look like:

http://<host>/formcycle/form/alias/1/demo?tfMail=johndoe@example.com

As shown in the figure to the right, this sets the initial value of the input field to the given email address.


Prefilling a select field

Setup in the FORMCYCLE Designer for prefilling a select field.

When opening the form, we set the URL parameter selSex. This sets the initial value of the corresponding select field.

You can preselect an option of a select field as well. Note that you cannot use the displayed name as the value of the URL parameter. You need to use the value specified in the values column of the options section in the properties panel of the FORMCYCLE Designer.

Create a select field with the name selSex. When you open the form, add the URL parameter selSex and set it to f. The URL could look like:

http://<host>/formcycle/form/alias/1/demo?selSex=f

As shown in the figure to the right, this preselects the option female.

You cannot prefill repeated elements. It is also not possible to set the initial number of repetitions via URL parameters.



Changing the form layout

To open a form with a different layout (CSS theme), use the URL paramter xfc-rp-theme and pass the UUID of the CSS theme as the value. The UUID is shown in the details panel (1) to the right hand side of the Layout (CSS) menu.

You can create different form layouts (CSS themes) in the Layout (CSS) menu. You can then assign one form layout to each form. If you want to open a form with a different layout, such as a blue or red variation of your main theme, you can use an optional URL parameter.

The name of the URL parameter is xfc-rp-theme, and its value needs to be the UUID of the form layout. You can view the UUID of each form layout in the Layout (CSS) menu (see screenshot to the right).

For example:

http://<host>/formcycle/form/alias/1/demo?xfc-rp-theme=<UUID>
http://<host>/formcycle/form/alias/1/demo?xfc-rp-theme=8b4a9c2d-34d9-4cff-8759-9b54ed4b0ff1

Limit login services

8.1.0


The URL parameter xfc-rp-use-auth lets you limit the list of available login services to a certain subset.


The value must be set to the callback UUID of the login service, as configured in the backend menu login services. You can specify the parameter multiple times to select multiple login services.


For this parameter to have an effect, you need to enable login services for the form via the form access menu. When set, only the specified login services are offered as login methods. If the list of login method contains only a single login service that support single sign-on (such as Kerberos), no login page is shown and an attempt is made to authenticate the user directly.


Example for a URL that limits the login methods to 2 login services:

http://example.com/xima-formcycle/form/provide/42?xfc-rp-use-auth=e259fb44-95d1-40bb-b502-57e1cc0966d1&xfc-rp-use-auth=eb6a8eb9-bcd6-406a-b2f9-98de89fca13e


Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article