Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Classic ASP Databases Discuss using ASP 3 to work with data in databases, including ASP Database Setup issues from the old P2P forum on this specific subtopic. See also the book forum Beginning ASP.NET Databases for questions specific to that book. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Databases section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old March 3rd, 2005, 10:07 AM
Authorized User
 
Join Date: Dec 2004
Location: Multan, Punjab, Pakistan.
Posts: 32
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to shankhan Send a message via Yahoo to shankhan
Default How to get IP address

hi guyz,

I've developed a site using VB script. It is running fine. Now i want to trace users. Like i want to get the IP address of users who is querying or inserting the data. is there anyway that i can save the IP address of everyuser in my database.

waiting for ur suggestions

Zee

Reply With Quote
  #2 (permalink)  
Old March 3rd, 2005, 10:14 AM
Friend of Wrox
 
Join Date: Jun 2003
Location: , , USA.
Posts: 1,111
Thanks: 0
Thanked 3 Times in 3 Posts
Default

Request.ServerVariables("REMOTE_ADDR")

Just save that to a table.

Reply With Quote
  #3 (permalink)  
Old March 4th, 2005, 07:15 AM
Authorized User
 
Join Date: Dec 2004
Location: Multan, Punjab, Pakistan.
Posts: 32
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to shankhan Send a message via Yahoo to shankhan
Default

Great ......... it is working fine.

Thanx friend

Reply With Quote
  #4 (permalink)  
Old March 4th, 2005, 01:57 PM
Authorized User
 
Join Date: Dec 2004
Location: Multan, Punjab, Pakistan.
Posts: 32
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to shankhan Send a message via Yahoo to shankhan
Default

Ok I got IP address of user. Now i want to get another thing that is user's computer name. can i get it like there is an object which returns us the IP address of user. and also tell me the others objects through which we can get the maximum information of user.

i shall be thankful to u.



Reply With Quote
  #5 (permalink)  
Old March 8th, 2005, 02:55 AM
Friend of Wrox
 
Join Date: Oct 2003
Location: Chennai, TamilNadu, India.
Posts: 326
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to Santhi Send a message via MSN to Santhi
Default

Go through this link.You will get an idea..
http://msdn.microsoft.com/library/de...l=/library/en-
us/cpref/html/frlrfsystemwebhttprequestmemberstopic.asp

Reply With Quote
  #6 (permalink)  
Old March 10th, 2005, 02:59 PM
Registered User
 
Join Date: Mar 2005
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

how do you collect this data(Request.ServerVariables("REMOTE_ADDR")) or call it from a form? do i have to create a hidden field? am trying to place users ip into a access db.....here is what i placed into my form:
<INPUT type="hidden" name="REMOTE_ADDR" value="REMOTE_ADDR">

and here is how i attempted to place in db;

ipaddress=request.form("REMOTE_ADDR")
Request.ServerVariables("REMOTE_ADDR")
ipaddress = "REMOTE_ADDR"
ipaddress.add "ipaddress",request.form("REMOTE_ADDR")

ANY HELP IS APPRECIATED..THANKS

GREG

Reply With Quote
  #7 (permalink)  
Old March 10th, 2005, 04:18 PM
Friend of Wrox
 
Join Date: Jan 2004
Location: , , USA.
Posts: 303
Thanks: 0
Thanked 0 Times in 0 Posts
Default

capture the IP address using Request.ServerVariables("REMOTE_ADDR"), you do not have to create a hidden field.
<%
Dim IPAddress
IPAddress = Request.ServerVariables("REMOTE_ADDR")
%>
and use that IPAddress in the SQL insert into clause
<%
Dim SQLString
SqlString = "INSERT INTO MyTable (IPAddressColumn) VALUES ('" & IPAddress & "')"

CommandObject.Execute (SQLString)

%>


Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Help me i must Get IP Address pla_2 C# 2005 2 October 12th, 2006 07:51 AM
IP Address sumanghosh Classic ASP Basics 1 April 7th, 2006 11:24 AM
How to track the IP address hums .NET Framework 2.0 5 October 20th, 2004 08:45 AM
Retreiving IP address & gateway address sjangit VBScript 0 February 3rd, 2004 02:02 PM



All times are GMT -4. The time now is 06:06 AM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.