Document – Dynamic Field for Elementor Forms

1. Introduction

Dynamic Field for Elementor Forms allows you to insert dynamic data into Elementor Forms fields.

You can display values from multiple sources such as:

  • Post Meta, User Meta, URL Parameter, Option, Current Date/Time, Shortcode
  • Database Query (fetch values directly from WordPress database tables)
  • CSV File (load values from uploaded CSV files)

👉 With this plugin, you can personalize forms for each user or pre-fill fields with existing data without writing custom code.

Table of contents:

2. Installation

  1. Install the plugin like any other WordPress plugin:
    • Go to Plugins → Add New → Upload Plugin.
    • Select the .zip file and click Install Now.
    • Click Activate to enable the plugin.
  2. Requirements:
    • Elementor and Elementor Pro (Form widget is required).
    • For Database Source, ensure you have access to your WordPress database.
    • For CSV Source, prepare a valid .csv file.

3. Usage – Dynamic Value

Dynamic Value lets you automatically fill field values in your form using data from various dynamic sources such as:

  • URL Parameters
  • User Meta
  • Post Meta
  • WordPress Options
  • Current Date / Time
  • Cookies
  • Shortcodes

3.1. Add Dynamic Field

  1. Open the Elementor Editor.
  2. Drag the Form widget onto the page.
  3. Select the field you want to make dynamic.
  4. Go to Advanced → Dynamic Source.
  5. Choose your data source:
    • Manual (Default) – keep the original field value.
    • Post Meta – fetch value from the current post’s meta key.
    • User Meta – fetch value from the logged-in user profile.
    • URL Parameter – fetch value from a query string (e.g., [email protected]).
    • Option – fetch value from wp_options.
    • Current Date/Time – insert current date/time.
    • Shortcode – execute a shortcode and return its output.

Add Dynamic Field to elementor form

3.2 URL Parameters

Use Case

Prefill form fields based on URL query strings.

Example:

Prefill form fields based on URL query strings.

Steps

  1. Edit your Elementor Form.
  2. Select the field you want to fill dynamically (e.g., Text, Email, Hidden).
  3. Go to the Advanced tab
  4. Set Dynamic SourceURL Parameter.
  5. In Dynamic Key, enter the parameter name (e.g., ref).
  6. Update your page.
  7. Test by adding ?ref=1234 to your page URL. → The field will automatically display “1234”.

3.3 User Meta

Use Case
Show logged-in user information like username, email, or first name.

Steps

  1. In the Form field
  2. Set Dynamic Source: User Meta.
  3. In Dynamic Key, enter a meta key — e.g.:
    • first_name
    • last_name
    • nickname
    • user_email
  4. Update your page and preview as a logged-in user. → The field will display the user’s meta data automatically.

3.4 Post Meta

Use case

Display post-specific data such as price, rating, or custom fields.

Steps

  1. Add a field (like Text or Hidden).
  2. Go to Advanced tab.
  3. Choose Dynamic Source: Post Meta.
  4. Set Dynamic Key to your custom field name (e.g., price, order_id).
  5. Update and preview the form on a post with that meta value.

3.5 Options

Use Case

Retrieve values from your site’s global settings (e.g., Site Title, Tagline).

Steps

  1. Choose Dynamic Source: Options.
  2. Dynamic Key examples:
    • blogname → Site Title
    • blogdescription → Tagline
  3. The field automatically displays the site’s information.

3.6 Current Date & Time

Use Case

Insert the current date/time automatically when someone opens the form.

Steps

  1. Choose Dynamic Source: Current Date&Time.
  2. Select format:
    • Date only (Y-m-d)
    • Time only (H:i:s)
    • Both combined
  3. Field will auto-fill with the user’s current date/time.

3.7 Cookies

Use Case

Prefill fields with stored browser cookie values (e.g., referral codes).

Steps

If you have a cookie named ref_code with value ABC123:

  • Choose Dynamic Source: Cookies
  • Dynamic Key: ref_code → The field will auto-display ABC123.

3.8 Shortcode

Use Case

Pull dynamic content from WordPress shortcodes.

Example:

If you have a shortcode [current_user_email],

you can use it as the field value to display user emails dynamically.

Steps

  1. Set Dynamic Source: Shortcode
  2. Dynamic Key: your shortcode name

4. Usage Dynamic Dropdown

Dynamic Options automatically populate Select, Radio, or Checkbox fields from external or dynamic data sources such as:

  • URL Parameters
  • Taxonomies (Categories, Tags)
  • Post Types (Posts, Products, etc.)
  • WordPress Options
  • CSV Files
  • Database

🔹 Dynamic Type

Choose the field will get data:

  • Disabled → don’t use dynamic, enter handle as usual.
  • Default Value → just autofill default value (e.g. prefill from URL, User Meta, etc.).
  • Option → automatically generate a list of choices (options) based on the data source you selected.

4.1 URL Parameters Dropdown

Use Case

Generate options from URL parameters.

Example:

?fruit=apple|orange|banana → Dropdown shows Apple, Orange, Banana.

Steps

  1. Add a Select field → Label: “Fruit List”.
  2. Leave Options blank.
  3. Go to AdvancedDynamic Type: Options.
  4. Set Dynamic Array Source: URL Parameter.
  5. Dynamic Key: fruit.
  6. Update and preview — dropdown will be empty at first.
  7. Add this to your URL: &fruit=apple|orange|banana
    → Dropdown now shows 3 options dynamically.

Generate options from URL parameters.

4.2 Taxonomy Terms

Use case

Populate dropdown or radio with WordPress taxonomy terms (e.g., Categories, Tags).

Steps

1. Add a Select or Radio field.

2. Set Dynamic Type: Options → Source: Taxonomy.
Once you select “Taxonomy,” a new dropdown will appear called Taxonomy.Click the list, and you’ll see all available taxonomies from your site such as:

  • Category — lists your blog post categories.
  • Tag — shows post tags.
  • Format — displays post formats if enabled.
  • Brand — often comes from WooCommerce or a product add-on.
  • Shipping class — WooCommerce’s product shipping categories.

The field automatically lists all terms under that taxonomy.

Example:
For example: choose category for blog categories

4.3 Post Type

Use Case

List posts, pages, WooCommerce products, or custom post types as options.

Steps

  1. Add a Radio or Select field → Label: “Select Product”
  2. Set Dynamic Type: Options → Source: Post Type
  3. Choose the post type:
    • Post → blog posts
    • Page → WordPress pages
    • Product → WooCommerce products
    • Template → Elementor templates
    • Media → files from Media Library
    • Floating Element → from Elementor add-ons
  4. The field will display all titles from that post type automatically.

4.4 WordPress Options

Use Case

Retrieve site data from WordPress settings.

Steps

  1. Add a Select field → Dynamic Type: Options
  2. Source: Options
  3. Example Dynamic Key:
    • blogname → Site Title
    • admin_email → Admin Email → Field options will show WordPress option values dynamically.

4.5 CSV File

Use Case
Import dropdown items from an uploaded CSV file (useful for large datasets).

Steps

  1. Prepare your CSV file (each value in a separate line or column).
  2. Upload it to your WordPress media library.
  3. Add a Select field → Dynamic Type: Options.
  4. Source: CSV File.
  5. Choose your uploaded file.
    → Dropdown now displays all values from your CSV.

4.6 Database

Use Case

Pull options directly from your WordPress database.

Example: list user names from the wp_users table.

Steps

  1. Add a Select or Radio field.
  2. Dynamic Type: Options
  3. Dynamic Source: Database
  4. Configure:
    • Table Name: wp_users
    • Column Name: display_name

Now the field will list all registered users automatically.

5. Examples

Example 1: Load data from Database

  • Form Field → Advanced → Dynamic Source → Database
  • Table: wp_users
  • Column: user_email 👉 The field will display user emails (according to your query settings).

Example 2: Populate Select from CSV file

  • Upload cities.csv with content:
id,name
1,Hanoi
2,Ho Chi Minh
3,Da Nang
  • Form Field → Advanced → Dynamic Source → CSV File
  • Select file: cities.csv
  • Column: name 👉 The Select field will show: Hanoi, Ho Chi Minh, Da Nang.

Example 3: Auto-fill Email from URL

  • URL:
https://example.com/[email protected]
  • Dynamic Source: URL Parameter
  • Parameter Name: email 👉 The Email field will be auto-filled with [email protected].

Example 4: Show logged-in user’s first name

  • Dynamic Source: User Meta
  • Meta Key: first_name 👉 If the user is logged in, the form will pre-fill with their first name.