• Home
  • Blog
  • Documentation
  • FAQ
    • Pre-Sales Questions
  • Log In
  • Get Easy Forms
  • Home
  • Blog
  • Documentation
  • FAQ
    • Pre-Sales Questions
  • Log In
  • Get Easy Forms
home/Knowledge Base/How To/Use a URL Query String to Specify Different Default Values for a Form
Popular Search:Getting Started

Use a URL Query String to Specify Different Default Values for a Form

893 views 3 August 6, 2020 admin

When we create a form in Easy Forms, one way we can distribute that form is with a URL. We can append a query string to the form URL such that when a person clicks the URL, information from the URL is passed into the form fields. This technique is useful, for example, if we need multiple people to fill out the same form but want to specify different default values in certain fields. To achieve this, we could create a URL that includes a unique query string for each person.

Add a Query String to a Form URL

Here’s how to build the query string for a form URL:

1. At the end of the URL, type a question mark (?). For example, type

https://demo.easyforms.dev/forms/simple-contact-form-with-recaptcha?

If your URL already has a question mark, you will need to use an ampersand (&).

2. Type in the value for the form field that you’d like to populate.

In this example, we want to populate the Rep field with the name of one of our sales reps:

https://demo.easyforms.dev/forms/simple-contact-form-with-recaptcha?text_0

Form fields are case sensitive. You can use the Field ID or Field alias.

3. Type = (an equal sign):

https://demo.easyforms.dev/forms/simple-contact-form-with-recaptcha?text_0=

4. Type the value you’d like to set as the default.

In this case, we’ll set the rep’s name to John Doe:

https://demo.easyforms.dev/forms/simple-contact-form-with-recaptcha?text_0=John%20Doe

5. Send the customized URL to the people who you want to use it.

In this example, we’d send the link to John. When she navigates to this link, the Name field will be populated with his name and he won’t have to enter it in manually.

To include multiple fields in the URL, join them with an ampersand. For example, use:

https://demo.easyforms.dev/forms/simple-contact-form-with-recaptcha?text_0=John%20Doe&[email protected]

Include Special Characters in the Query String

You can see a full list of Special Characters (referred to as escape characters) here.

URLs cannot contain spaces. To include a space or other special character using the method described in this article, you’ll need to use URL percent encoding. The following table includes a few common special characters and their percent encoding values. Use these in the query string to populate the form with their ASCII values.

To populate this Type this in the URL
To populate this Character space Type this in the URL %20
To populate this = (equal sign) Type this in the URL %3D
To populate this % (percent symbol) Type this in the URL %25
To populate this # (number symbol) Type this in the URL %23
To populate this $ (US dollar) Type this in the URL %24
To populate this & (ampersand) Type this in the URL %26
To populate this ` (grave diacritic) Type this in the URL %60
To populate this : (colon) Type this in the URL %3A
To populate this < (less than) Type this in the URL %3C
To populate this > (greater than) Type this in the URL %3E
To populate this [ (open bracket) Type this in the URL %5B
To populate this ] (close bracket) Type this in the URL %5D
To populate this { (open curly bracket) Type this in the URL %7B
To populate this } (close curly bracket) Type this in the URL %7D
To populate this ” (quotation marks) Type this in the URL %22
To populate this + (plus sign) Type this in the URL %2B
To populate this @ (at sign, arobase) Type this in the URL %40
To populate this / (forward slash, whack) Type this in the URL %2F
To populate this ; (semi-colon) Type this in the URL %3B
To populate this ? (question mark) Type this in the URL %3F
To populate this \ (backslash)  Type this in the URL %5C
To populate this ^ (caret, chevron) Type this in the URL %5E
To populate this | (pipe, pine) Type this in the URL %7C
To populate this ~ (tilde) Type this in the URL %7E
To populate this ‘ (apostrophe) Type this in the URL %27
To populate this , (comma) Type this in the URL %2C

Was this helpful?

3 Yes  No
Related Articles
  • How to enable/disable the autofocus on the first field
  • How to Set Current Date in Date Field
  • How to Show/Hide HTML elements with Conditional Rules
  • How to Embed the Same Form Multiple Times on the Same Page?
  • How to Submit a Form as WhatsApp Message
  • How to Create Multi-Page Forms to Increase Conversions: Survey Funnel

Didn't find your answer? Contact Us

Leave A Comment Cancel reply

You must be logged in to post a comment.

How To
  • Use a URL Query String to Specify Different Default Values for a Form
  • How to enable/disable the autofocus on the first field
  • How to Set Current Date in Date Field
  • How to Show/Hide HTML elements with Conditional Rules
  • How to Embed the Same Form Multiple Times on the Same Page?
  • How to Submit a Form as WhatsApp Message
View All 24  
Popular Articles
  • How to Show/Hide HTML elements with Conditional Rules
  • How to enable / disable DEBUG mode
  • How to Submit a Form as WhatsApp Message
  • How to update Form Stats from the command line
  • How to compare two fields to pass the validation (jQuery Validation)
KB Categories
  • Add-Ons
  • Advanced Techniques
  • Common Issues & Troubleshooting
  • Developers "How To's"
  • Getting Started
  • How To

  Using Submission ID as an Order Confirmation Number

Session Timeout: Automatic Logout after minutes or hours of User Inactivity  

About Easy Forms

With Easy Forms you can create unlimited web forms and most importantly the complete management of them without paying monthly fees

Resources
  • Knowledge Base
  • Documentation
  • Pre-sales Questions
  • Blog
Useful Help Links
  • Get Easy Forms
  • Live Demo
  • License Terms
  • Contact Us
Frequent Visit Links
  • Pre-Sales Questions
  • System Requirements
  • Installing Easy Forms
  • Upgrading Easy Forms
  • Privacy Policy
  • © 2015 - 2024 Baluart EIRL. All Rights Reserved.

Popular Search:Getting Started