what-is-a-wpforms-hidden-field-hacks-to-find-user-data_o

What Is a WPForms Hidden Field? (6 Hacks to Find Hidden User Data)

Wondering what a WPForms hidden field is and how it can help you uncover your form users’ data?

You can set up hidden fields to get tons of hidden data like locations, IP addresses, spammer detection, and more from people who fill out forms on your website.

In this guide, we’ll show you what a WPForms hidden field is and hacks to use them to get you data on your visitors.

What Is a WPForms Hidden Field?

Asking yourself what is a WPForms Hidden Field? You’re in the right place.

WPForms is the best WordPress Form Builder plugin. Get it for free!

A WPForms Hidden Field is a field that you can add to your forms that is not visible to users. This hidden field can capture information from the form user without them being able to edit the field, or to see this field at all.

wpforms hidden field example

Why would you want to use a WPForms hidden field?

Well, In WPForms, you can use Smart Tags to collect information which may be useful for you to see in an entry, but would likely be confusing to a visitor if they could see that field while filling out the form. These Smart Tags can give you all sorts of hidden information on the people filling out your web forms.

So now that you know what a WPForms Hidden Field is, let’s check out some awesome hacks you can use to find user data with them.

WPForms Hidden Field Hacks

Here are the best hacks you can use WPForms Hidden Fields for you to use on your forms to uncover customer data:

1. Find IP Addresses

Did you know that every computer using the internet contains a unique address? They do, and it’s called an IP Address.

You can track IP Addresses from your form users without them seeing it, simply by inserting a Smart Tag into your hidden field.

user ip in wpforms hidden field

Capturing IP Addresses can be especially helpful for fighting form spam.

Because when you see which IP Address is sending you spam, you can block that address from accessing your site at all through your hosting company or a security plugin. It’s important to follow best practices for WordPress security tips for online forms.

2. See How People Found You

The {url_referer} Smart Tag will capture the page address that referred the user to your form.

For example, if a user was on your home page and then navigated to your contact page before filling out your form, this Smart Tag would give you the URL of your home page.

Now that you’ve got form tracking down with Smart Tags, don’t miss this post on tracking user engagement on your site.

You can also use hidden fields to find this from external sources. For example, if a user visited your website by clicking on a special tracking link such as yoursite.com/page/?source=facebook, you’ll be able to see that in your form entries.

To do this, simply add a Query Variable Smart Tag to your hidden field and name it ‘Source’.

wpforms hidden field hacks to find source

After this, you’ll want to include the information from this field in your notification email. Go to Settings » Notifications. From there, select the message body on the right side preview panel. Next, click on Show Smart Tags in the top right of the message box.

choose message field in notification settings for wpforms hidden field

Scroll to the Hidden Field choice and select it.

It will add some code to your notification that looks like {field_id=" "} with a number.  Click save and your form is ready to be published on a post or page.

The final step for this is to share the link to the page that contains this form. For each platform you share the link on (Facebook, Twitter, etc.), you’ll want to add the source to the end of the link. That way WPForms can recognize it.

Here’s how you would create each link depending on where you shared ut:

  • Facebook — yoursite.com/page/?source=facebook
  • Twitter — yoursite.com/page/?source=twitter
  • Email Newsletter — yoursite.com/page/?source=newsletter

You can change the source to whatever text you want. Then, when someone fills out a form on your site, they won’t even see this info attached to their form.

3. Campaign Tracking

If you’ve done more than one marketing campaign, you may want to track which one is performing the best.

This can be done by tracking which campaigns are sending people to the form submission page. You can do this by following the tutorial above in Step 2 and setting up a url like http://www.example.com?campaigname=xyz. Then, add a hidden field with a Campaign Name variable on the form to track it.

After that, when users fill out a form, their submission will tell you which campaign sent the users there. And it all happens right in the form entry.

4. Find User Locations

If you’re already loving the Geolocation addon that lets you see where your users are located, you might want to consider adding the user location Smart Tag into the Message field of the notification settings in the form builder.

You might also love our post on ways to reduce SaaS bills with open source alternatives.

This would be helpful if you want to see the user location in a notification email so you don’t have to sign in to your Dashboard and form entry to find it. And, this can be particularly great if you need to know their time zone for a phone call.

Just go to Settings » Notifications. Then, select the message body on the right side.choose message field in notification settings for wpforms hidden field

Now, paste{entry_geolocation} into the message box.

entry geolocation tag

Once you hit save, you’ll now receive form locations in your form notification emails.

Did you know you can accept files on your forms by creating a WordPress upload widget?

5. Assign User IDs

Want to know who your visitors are but don’t want to ask their name? Assign a User ID so you can see what they’ve been up to on your site.

Every registered user is automatically assigned an ID number on your WordPress site. The User ID Smart Tag allows you to see that very User ID when a form is submitted by a logged in user. This can be especially helpful if you’re creating a survey and want to see which users filled it out.

6. Block Specific Email Addresses

If you do know a bit about code, you can easily block email addresses from your forms. This is super helpful if you’ve noticed specific email addresses may be spammers. That way, you can stop their entries from being saved all together.

You’ll just need this bit of code:

 /* * Blacklist emails from your WPForms. * * @link https://wpforms.com/developers/how-to-block-email-addresses-from-your-forms/ * */ function wpf_dev_blacklist( $honeypot, $fields, $entry, $form_data ) { // Use the email as the key. The value will be used in the log $blacklist = array( '123test@me.com' => 'Ima Believer', 'me@me.com' => 'Me Me' ); foreach( $form_data['fields'] as $id => $field ) { if( 'email' == $field['type'] && array_key_exists( $entry['fields'][$id], $blacklist ) ) $honeypot = '[Blacklist] ' . $blacklist[$entry['fields'][$id]]; } return $honeypot; } add_filter( 'wpforms_process_honeypot', 'wpf_dev_blacklist', 10, 4 ); 

Check out our doc on how to block email addresses from your forms to see exactly how it’s done.

Final Thoughts on WPForms Hidden Field

And there it is! You now have some great hacks for using the WPForms hidden field to find extra data about your form users.

If you want to add even more custom fields to you forms, read about how to add a coupon code field next.

So what are you waiting for? Get started with the most powerful WordPress forms plugin today.

And if you like this article, then please follow us on Facebook and Twitter for more updates from our blog.

Using WordPress and want to get WPForms for free?

Enter the URL to your WordPress website to install.

Add a Comment

We're glad you have chosen to leave a comment. Please keep in mind that all comments are moderated according to our privacy policy, and all links are nofollow. Do NOT use keywords in the name field. Let's have a personal and meaningful conversation.