Complete Request Object Reference
The Form collection is used to retrieve the values of form elements from a form that uses the POST method.
| Parameter | Description |
|---|---|
| element | Required. The name of the form element from which the collection is to retrieve values |
| index | Optional. Specifies one of multiple values for a parameter. From 1 to Request.Form(parameter).Count. |
You can loop through all the values in a form request. If a user filled out a form by specifying two values - Blue and Green - for the color element, you could retrieve those values like this:
Output:
Consider the following form:
The following request might be sent:
Now we can use the information from the form in a script:
Output:
If you do not specify any element to display, like this:
the output would look like this:
Complete Request Object Reference
Your message has been sent to W3Schools.