Set Default From Value from URL Parameters
WP Fluent Forms allows you to set input values using the URL GET parameters feature. This feature enables you to populate input fields automatically which can be very useful for advanced users. Let us show an example of how you can implement it quickly.
- Go to Fluent Forms>All Forms.
- Select the form you want to set default values and click the Edit button below it.
- Add the input fields in which the value needs to be set from the URL or select the already existed one. In my case, It’s the email field.
- Go to the advanced option.
- Click the dropdown icon of the Default Value field.
- Select the first option ” Populate by GET Param”. Please remember the “Name Attribute” which is email in our case. Follow again the same steps for other fields, in my example another field name is “Age” and I am setting its default value to “Populate by GET param” also.
- Now, let’s create a page using the table shortcode with this table.
- Copy the values of your “Name Attribute” field. In my case, For email input the “Name Attribute” is email and for age input the “Name Attribute” is age.
- Publish and go to the page. In the URL place this sign “?” with your field attribute and your desired value. In our example, the URL is: email@example.com
- You can see after the name attribute, we have placed an equal “=” sign between our attribute and value. And you can see the fields are automatically populated now fetching the value from URL. You can use as many parameters as you need.