...

View Full Version : IP address + domain lookup script



ebay258
06-03-2006, 08:42 PM
Where can I get a script that looks up IP addresses and domain name just like http://cqcounter.com/whois/

I've seached everywhere without sucess.

Thanks in advance.

v777tony
06-03-2006, 11:16 PM
This code gets the IP address. You can use it anyway you want such as in an alert box or in plain text.



<head>
<script type="text/javascript">
var ip = '<!--#echo var="REMOTE_ADDR"-->'
</script>
</head>


As for domain lookup. I'm not sure but I know in MS-DOS you can use the "ping" command to find an IP.
Here's an example:

Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.

DIRECTORY>ping codingforums.com
Pinging codingforums.com [207.150.176.83] with 32 bytes of data:

Reply from 207.150.176.83: bytes=32 time=94ms TTL=42
Reply from 207.150.176.83: bytes=32 time=93ms TTL=42
Reply from 207.150.176.83: bytes=32 time=93ms TTL=42
Reply from 207.150.176.83: bytes=32 time=94ms TTL=42
Ping statistics for 207.150.176.83:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 93ms, Maximum = 94ms, Average = 93ms

ebay258
06-05-2006, 11:28 PM
You don't understand. I own an IP address related site and I want to offer a service just like: http://cqcounter.com/whois/

I has the ability to look up IP and domain whois.

v777tony
06-06-2006, 08:32 PM
You don't understand. I own an IP address related site and I want to offer a service just like: http://cqcounter.com/whois/

I has the ability to look up IP and domain whois.

You could always use the iframe tag.



<iframe src="http://cqcounter.com/whois (http://cqcounter.com/whois/)" width="460" height="300"></iframe>

Beagle
06-06-2006, 08:43 PM
They aren't using javascript to do that. You can't.

With AJAX the most you can do is open an HTTP connection. If you can find a service that uses the HTTP protocol to make these requests and returns the results in plain text, awesome.

But the site you're referencing is using server-side code to do what they're doing.

brownk4
05-22-2011, 07:27 PM
Where can I get a script that looks up IP addresses and domain name just like http://cqcounter.com/whois/

I've seached everywhere without sucess.

Thanks in advance.

Successful results would be retrieved from the website whoisxy. com for domain,ip adress lookup.Here you can also get the DNS result and ping test results also.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum