ServerVariables

Another collection provided by the Request object is ServerVariables. Any HTTP header that is sent by a client browser is available in this collection with code such as the following:

Dim strValueData as String 
strValueData = Request.ServerVariable( “HeaderType” ) 

The standard HTTP headers are automatically defined as members of the ServerVariables collection. For example, when form data is sent to the server, the method by which it was sent can be determined from

Dim strRequestMethod as String 
strRequestMethod = Request.ServerVariables( “REQUEST_METHOD” ) 
' Either GET or POST 

You can also use the QUERY_STRING header to obtain the original unadulterated query string that was passed to the server from the browser. A great ...

Get Special Edition Using® Microsoft® ASP.NET now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.