ASP equivalent to PHP's $_SERVER superglobal

the_net_2.0

Banned
Local time
Today, 13:12
Joined
Sep 6, 2010
Messages
812
does anyone know if ASP has the same resource as PHP does? (as in title). If the readers are not familiar with PHP, the 'server' global can return things like remote IP address, browser type, host name, etc...

thanks!
 
I have used this in the past, I can't remember where!!
Code:
<%@ LANGUAGE="VBSCRIPT" %>
<HTML>
<HEAD>
<title>Server Variables</title>
</HEAD>

<body bgcolor="#FFFFFF" text="#000000" link="#804040" vlink="#008080" alink="#004080">
<HTML>
<BODY>
<div align="left">
<table border="0" cellpadding="0" cellspacing="0" width="750">
<tr>
<td valign="top" align="left" width="150"><font face="Arial" size="2" color="#FF0000"><b>Variable Name</b></font></td>
<td valign="top" align="left" width="600"><font face="Arial" size="2"><b>Value</font></b></td>
</tr>
<%
for each name in request.servervariables
%>
<tr>
<td valign="top" align="left" width="150">
<font face="Arial" size="1" color="#FF0000">
<%= name %></font></td>
<td valign="top" align="left" width="600">
<font face="Arial" size="1"><%= request.servervariables(name) %></font></td>
</tr>
<%
Next
%>
</div> 
</BODY>
</HTML>

Simon
 

Users who are viewing this thread

Back
Top Bottom