Request.QueryString






Request.QueryString

The Request.QueryString command is used to collect values in a form with method="get".

Information sent from a form with the GET method is visible to everyone (it will be displayed in the browser's address bar) and has limits on the amount of information to send.

Example HTML form

<form method="get" action="simpleform.asp">
First Name: <input type="text" name="fname"><br>
Last Name: <input type="text" name="lname"><br><br>
<input type="submit" value="Submit">
</form>

If a user typed "Bill" and "Gates" in the HTML form above, the URL sent to the server would look like this:

http://www.w3schools.com/simpleform.asp?fname=Bill&lname=Gates

Assume that "simpleform.asp" contains the following ASP script:

<body>
Welcome
<%
response.write(request.querystring("fname"))
response.write(" " & request.querystring("lname"))
%>
</body>
The browser will display the following in the body of the document:

Welcome Bill Gates










( requestquerystring.html )- by Paolo Puglisi - Modifica del 17/12/2023