Skip to content
  • ZipCode Api
  • Blog
  • About RedLine13
RedLine13
RedLine13
Primary Navigation Menu
Menu
  • Start Testing
  • Demo
  • Pricing
  • JMeter
  • Partners
  • Docs
    • Documentation Home
    • AWS Set Up for load testing
    • AWS Approval for Large Tests
    • PHP, NodeJS, Python Load Tests
    • Scalability
    • Jenkins Plugin Setup
    • Premium Features
    • Knowledge Base

Using the HTTP Form Manager in JMeter

By: David Koziel

Using the HTTP Form Manager in JMeter

Form submissions represent a common use case for performance tests. If your JMeter test needs to automatically fill out form fields from a data source, this is classically done with extractors and variable substitution.  Depending on the number of fields in your form and the structure of your web page, this can become complicated.  To simplify this process, we will show you how to use the HTTP Form Manager plugin.  This component allows you to intuitively specify form data by automatically matching variables to named fields.

Configuring the HTTP Form Manager

To add the HTTP Form Manager to your test plan, right click on the test plan tree and find the component under “Preprocessors”:

The HTTP Form Manager can be added to your test plan as a preprocessor
The HTTP Form Manager can be added to your test plan as a preprocessor.

Configuration for the HTTP Form Manager is straight-forward and minimal.  For most instances, the following default configuration options should suffice:

The HTTP Form Manager can be added to your test plan as a preprocessor
The HTTP Form Manager can be added to your test plan as a preprocessor.

Populating HTTP Requests with Form Data

The HTTP Form Manager will apply itself to any applicable HTTP Request instances that exist within the same scope.  In the following example we are substituting a username and password for a login form, matching named fields with variables (e.g., from an instance of a CSV Data Set Config).

Sample HTTP Request referencing form fields exposed by an HTTP Form Manager
Sample HTTP Request referencing form fields exposed by an HTTP Form Manager.

For the HTTP Request to correctly submit form values, you will need to ensure that the “multipart/form-data” option is selected as shown above.  The parameters in the table will be substituted into form fields by name, such that the “username” field will be matched to the following example HTML code in the target application page:

<input id="uid" type="text" name="username" value="" />

Did you know that RedLine13 offers a full-featured, time-limited free trial?  Sign up now, and move your JMeter testing into the cloud today!

2024-05-15
Previous Post: Using X-Forwarded-For in JMeter
Next Post: Dynamically Parse HTML with k6

Recent Posts

  • JMeter XML Format Post Processor
  • Order of Elements in JMeter
  • The JMeter Synthesis Report
  • Using the JMeter Plugins Manager
  • JMeter Rotating JTL Listener

Related

  • JMeter XML Format Post Processor
  • Order of Elements in JMeter
  • SAML Configuration with Azure AD and RedLine13
  • SAML Configuration with OKTA and RedLine13
  • SAML Configuration with Google and RedLine13
  • The JMeter Synthesis Report
  • Using the JMeter Plugins Manager
  • JMeter Rotating JTL Listener
  • Using Test Fragments in JMeter Tests
  • Step-by-Step Guide to Testing with JMeter

© RedLine13, LLC | Privacy Policy | Contract
Contact Us: info@redline13.com

Designed using Responsive Brix. Powered by WordPress.