Forums

ASP

This topic is locked

Browser info via ASP?

Posted 28 Aug 2003 10:28:48
1
has voted
28 Aug 2003 10:28:48 Bec C posted:
<font face='Arial'>I would like to find out where viewers are coming from - country, browser type etc. Is there a way I can grab this info from via ASP?</font id='Arial'>

Replies

Replied 08 Sep 2003 14:10:37
08 Sep 2003 14:10:37 Vince Baker replied:
&lt;%
Dim strLang
strLang = Request.ServerVariables("HTTP_ACCEPT_LANGUAGE"
%&gt;

This will set a variable 'strLang' with the language of the browser of the user.

To view all available server info use the following and then run the page and pick the variables you want to use.

&lt;%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%&gt;
&lt;html&gt;
&lt;head&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;% Response.write(Request.ServerVariables("ALL_HTTP") %&gt;
&lt;/body&gt;
&lt;/html&gt;

Regards
Vince

Visit my home: www.chez-vince.com

VBScript | ASP | HTML | SQL | Oracle | Hosting

Edited by - bakerv on 08 Sep 2003 14:11:23

Reply to this topic