List every ServerVariable stored by the webserver

Normaly added to the bottom of your ASP code (footer.asp) for testing only.


<%
For Each var In Request.ServerVariables
Response.Write var & " = " & Request.ServerVariables(var) & "<br>"
Next
%>

Output is as follows

<span style="font-size: x-small;">ALL_HTTP:<span style="font-size: x-small;">HTTP_ACCEPT<span style="font-size: x-small;">:*/* HTTP_ACCEPT_LANGUAGE:en-gb HTTP_CONNECTION:Keep-Alive HTTP_HOST:mydomain.co.uk HTTP_USER_AGENT:Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729) HTTP_COOKIE:ASPSESSIONIDAQSATTBS=BLADACMABJAGMKJPDFPPBONA HTTP_ACCEPT_ENCODING:gzip, deflate
ALL_RAW:Accept: */* Accept-Language: en-gb Connection: Keep-Alive Host: mydomain.co.uk User-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729) Cookie: ASPSESSIONIDAQSATTBS=BLADACMABJAGMKJPDFPPBONA Accept-Encoding: gzip, deflate
APPL_MD_PATH:/LM/W3SVC/1/ROOT
APPL_PHYSICAL_PATH:c:\inetpub\wwwroot\
AUTH_PASSWORD:
AUTH_TYPE:
AUTH_USER:
CERT_COOKIE:
CERT_FLAGS:
CERT_ISSUER:
CERT_KEYSIZE:
CERT_SECRETKEYSIZE:
CERT_SERIALNUMBER:
CERT_SERVER_ISSUER:
CERT_SERVER_SUBJECT:
CERT_SUBJECT:
CONTENT_LENGTH:0
CONTENT_TYPE:
GATEWAY_INTERFACE:CGI/1.1
HTTPS:off
HTTPS_KEYSIZE:
HTTPS_SECRETKEYSIZE:
HTTPS_SERVER_ISSUER:
HTTPS_SERVER_SUBJECT:
INSTANCE_ID:1
INSTANCE_META_PATH:/LM/W3SVC/1
LOCAL_ADDR:127.0.0.1
LOGON_USER:
PATH_INFO:/index.asp
PATH_TRANSLATED:c:\inetpub\wwwroot\index.asp
QUERY_STRING:
REMOTE_ADDR:127.0.0.1
REMOTE_HOST:127.0.0.1
REMOTE_USER:
REQUEST_METHOD:GET
SCRIPT_NAME:/index.asp
SERVER_NAME:mydomain.co.uk
SERVER_PORT:80
SERVER_PORT_SECURE:0
SERVER_PROTOCOL:HTTP/1.1
SERVER_SOFTWARE:Microsoft-IIS/5.1
URL:/index.asp
HTTP_ACCEPT:*/*
HTTP_ACCEPT_LANGUAGE:en-gb
HTTP_CONNECTION:Keep-Alive
HTTP_HOST:mydomain.co.uk
HTTP_USER_AGENT:Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)
HTTP_COOKIE:ASPSESSIONIDAQSATTBS=BLADACMABJAGMKJPDFPPBONA
HTTP_ACCEPT_ENCODING:gzip, deflate
Print Friendly
  1. No comments yet.

  1. No trackbacks yet.