1. Home
  2. Docs
  3. Form Field Types
  4. Name Field

Name Field

The name field for weForms, the best wordpress contact form plugin, allows you to create fields in your form where users can input their name. It is divided into two sections by default – First Name and Last Name.

To add this field type to your form, simply click on the Name field from the Custom Fields section or drag and drop it in the builder.

Name Field Options

This field has several default options including –

  • Field Label: This is the text that your users will see on the form for the name field. You can put any text here that helps the user understand the purpose of this field.
  • Meta Key: You can customize the meta key from here. Keep in mind, a meta key is automatically generated according to the field label that you provide.
  • Help Text: You can put help text for this field to make the form more user-friendly and understandable.
  • Required: This option allows you to make this field either required for submitting the form or optional.

Advanced Options

To enable advanced options, click on the Advanced Options menu on the Field Options tab. You will find a new set of options.

  • Format: You can customize the format of the name field. There are two formats – (1) First and Last Name, (2) First, Middle and Last Name.
  • Placeholder & Default Value: You can include a placeholder and the default value for all the sections of the name field.
  • CSS Class Name: This option helps to include a CSS class for this field.
  • Hide Sub Labels: You can hide the sub-labels if you want using this option.
  • Dynamic value population: Being able to dynamically populate the Name field’s value adds great user-friendliness to your contact form. Here is the “Dynamic value population” field option:

Check the “Allow field to be populated dynamically” option to populate the field value of the Name field. After having checked the option, you will notice a field named “Parameter Name” appear underneath the “Allow field to be populated dynamically” option.

In order to make the field dynamically populated, enter a random parameter name of your choice, and save the form. Next, you will have to use this parameter name in a filter hook or query string to make the Name field dynamic. See this tutorial to learn “How to use dynamic field population on weForms”.

  • Auto-Populate Name: If you enable this field option, then the logged-in users will not see the Name field while they want to fill out and submit the form.

Now, let’s see how it works. First, leave the “Auto Populate Name” field property unchecked. Now save the form and hit preview. Next, just fill out the form with random data:

Hit, Submit Query button. You will see the following success message:

It means that your user has already logged in. Now, get back to the field property and enable the “Auto Populate Name”.

Hit the Save Form button and click on preview again. Then, the Name field will not appear since you checked the “Auto Populate Name” box. Here is a screenshot:

In this case, the name that the user inputted initially will be submitted automatically. This option is pretty handy for your users because they don’t need to enter the same thing over and over.

For any further queries, contact our support team.

Was this article helpful to you? Yes No 2