Print Page | Close Window

IP Address

Printed From: Web Wiz Forums
Category: General Discussion
Forum Name: Classic ASP Discussion
Forum Description: Discussion on Active Server Pages (Classic ASP).
URL: https://forums.webwiz.net/forum_posts.asp?TID=1071
Printed Date: 29 March 2026 at 2:07pm
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: IP Address
Posted By: William Rendell
Subject: IP Address
Date Posted: 17 March 2003 at 4:13am

Hi, is there a way I can display a users IP address on a page using ASP?

Thanks

Will




Replies:
Posted By: Gary
Date Posted: 17 March 2003 at 4:43am

<%
IPAddr = Request.ServerVariables("remote_addr")
Response.Write("Your IP Address is " * IPAddr)
%>



Posted By: William Rendell
Date Posted: 17 March 2003 at 4:53am

Thanks Gary

I have tried what you suggested, but I get the following error

 Microsoft VBScript runtime error '800a000d'

Type mismatch: '[string: "Your IP Address is "]'

/src/ip.asp, line 14



Posted By: Gary
Date Posted: 17 March 2003 at 4:54am

Opps - typo, sorry.....

<%
IPAddr = Request.ServerVariables("remote_addr")
Response.Write("Your IP Address is " & IPAddr)
%>



Posted By: William Rendell
Date Posted: 17 March 2003 at 5:18am
Works Now thanks very Much



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net