Form data in requests
- Last Updated: January 16, 2024
- 1 minute read
- OpenEdge
- Version 12.8
- Documentation
HTML forms are a popular way to capture and transmit sets of data. Take, for example, a registration page that includes fields such as name, email, and contact number. Each field has a name and a value. When a user clicks Submit on the page, data from the page is sent to the backend service as form data.
Form data is a set of key-value pairs. The value of a key can be a string, a
JSON object, or an image. To add form data to an HTTP request, use the AddFormData() method. For example:
|
To send a JSON object in the form data, convert it to string. For example:
|