Monday, March 22, 2010

How to Retrieve a Cookie Value?

The "Request.Cookies" command is used to retrieve a cookie value.
In the example below, we retrieve the value of the cookie named "firstname" and display it on a page:

<% fname=Request.Cookies("firstname") response.write("Firstname=" & fname) %>
Output: Firstname=Alex