Back to tutorials
User / Level Icon
Intermediate
Gear Time Icon
Webflow
Time Icon
5
 Minutes

CMS Unique Form Submissions

Dereksiu.com.au - Derek Siu Headshot smiling

Taught by:

Derek Siu

​Enhancing your Webflow CMS forms by incorporating hidden input fields allows you to capture dynamic data, leading to more personalized and informative email notifications. This tutorial will guide you through the process of adding hidden fields to your forms, enabling you to identify the specific CMS page from which each submission originates.​

<input type="hidden" id="item" name="CHANGE_THIS" value="CHANGE_THIS">

Copy Code

Understanding Hidden Input Fields in Webflow Forms

Hidden input fields are form elements that are not visible to users but can store data to be submitted with the form. In Webflow, adding hidden fields can help track information such as the page URL or CMS item associated with the form submission.​

Steps to Add Hidden Fields to Your Webflow CMS Forms

  1. Access Your Webflow Project:
    • Open your Webflow project and navigate to the CMS Collection page containing the form you want to modify.​
  2. Add an Embed Element:
    • Within the form block, drag an Embed element to the desired location. This will allow you to insert custom code.​
  3. Insert the Hidden Input Field Code:
    • In the Embed code editor, input the following HTML code:​Forum | Webflow
    • <input type="hidden" id="item" name="item" value="">
    • Ensure that the name attribute matches the field you want to capture, and the value attribute is dynamically set to pull data from the CMS.​
  4. Bind CMS Data to the Hidden Field:
    • Replace the value attribute with the appropriate CMS field. For example, if you want to capture the page URL, modify the code as follows:​
    • <input type="hidden" id="pageURL" name="pageURL" value="{{wf {&quot;path&quot;:&quot;slug&quot;,&quot;type&quot;:&quot;PlainText&quot;\} }}">
    • This setup dynamically assigns the page's slug to the hidden field.​
  5. Save and Publish Your Changes:
    • After embedding the code, save your changes and publish the site to ensure the hidden field functions correctly.​

Verifying the Functionality

To confirm that the hidden field is capturing the intended data:​

  • Submit a Test Form:
    • Navigate to the live site and complete the form to generate a submission.​
  • Check the Form Submission Data:
    • Access the form submissions through Webflow's dashboard or your email notifications to verify that the hidden field's data is correctly included.​
By following these steps, you can effectively incorporate hidden fields into your Webflow CMS forms, enabling dynamic data capture and enhancing the personalization of your email notifications.
How Did You Find This Tutorial?
Ready to implement this tutorial?
Get started with Webflow Today!
Webflow Icon Logo
Signup For A Free Webflow Account
Stay updated with my Newsletter!
Have Any Further Questions?
Contact Me
Basic Linkedin Icon
Basic Pinterest Icon
Basiic Maill iicon