Help me with this please!!!

Thread Solved

Join Date: Apr 2008
Posts: 26
Reputation: maddogsprofiles is an unknown quantity at this point 
Solved Threads: 0
maddogsprofiles's Avatar
maddogsprofiles maddogsprofiles is offline Offline
Light Poster

Help me with this please!!!

 
0
  #1
Jul 20th, 2008
I am making a whatsmyip.org clone and this is what I have so far
  1. <HTML>
  2. <HEAD>
  3. <TITLE>Maddog's IPs'</TITLE>
  4. <META NAME="Keywords" CONTENT="IP, address, find ip address, ip addres, whats ip, ip find, ipconfig, ipaddress">
  5. <META NAME="Description" CONTENT="Maddog's IP' - The #1 Way To Find Your IP Address !">
  6. <META HTTP-EQUIV="Pragma" CONTENT="no-cache">
  7. <LINK TITLE="" HREF="ip.css" TYPE="text/css" REL="stylesheet">
  8. </HEAD>
  9. <body>
  10. <div align="center">
  11. <SCRIPT TYPE="text/javascript"><!--
  12. doad2();
  13. //--></SCRIPT>
  14. <table class="maintable" align="center" border="1" cellSpacing="0" cellPadding="0">
  15.  
  16. <tr>
  17. <td class="head"><div align="left"><img src="http://www.maddogsprofiles.com/flash/WHITEBAN.jpg" width="885" height="150"></div></td>
  18. <tr>
  19. <td class="ip"><h1 align="center">Your IP Is
  20. <p align="center">
  21. <?php $ip = $_SERVER['REMOTE_ADDR'];
  22. echo "<b>IP Address = $ip</b>"; ?></h1>
  23. <h3 align="center"> <text>You are currently viewing this page in <text/> <map id="browser" ''name="firefox" "name="safari" "name="konqueror" name="internet explorer" name="opera" name="lynx" name="flock" name="netscape navigator" name="mosaic" ></map> <script> document.write( document.getElementById('browser').getAttribute('name')); </script>.
  24. </p>
  25. </td>
  26. </tr>
  27. <tr>
  28. <a href="mailto:webmastermaddog@maddogsprofiles.com" td height="88" class="ad"><img src="ad.gif" width="743" height="87"> </a>
  29. <SCRIPT TYPE="text/javascript"><!--
  30. doad1();
  31. //--></SCRIPT> </td>
  32. <tr>
  33. <td class="body">
  34.  
  35. <h3 align="center">Maddog's IPs' is the fastest and easiest way<br />to determine your IP address.</h3>
  36. <p>
  37. <h3 align="center">
  38. <form action="http://www.google.com/cse" id="cse-search-box">
  39. <div>
  40. <input type="hidden" name="cx" value="013221771976019527881:6kzpwitkmxy" />
  41. <input type="hidden" name="ie" value="UTF-8" />
  42. <input type="text" name="q" size="31" />
  43. <input type="submit" name="sa" value="Search" />
  44. </div>
  45. </form>
  46. <script type="text/javascript" src="http://www.google.com/coop/cse/brand?form=cse-search-box&lang=en"></script>
  47. Copyright Maddog Noland Programming All Rights Reserved </div></td>
  48. </tr>
  49. </table>
  50. </div>
  51. </BODY>
  52. </HTML>
but I want to get it to show the computer country of origin, and host of the visitors internet like on the "more info" page at whatsmyip.org does anyone know how???
OHS=The Future!
Reply With Quote Quick reply to this message  
Join Date: Aug 2007
Posts: 189
Reputation: martin5211 is an unknown quantity at this point 
Solved Threads: 14
martin5211 martin5211 is offline Offline
Junior Poster

Re: Help me with this please!!!

 
0
  #2
Jul 21st, 2008
To show the origin country, a general way is to lookup into a MySQL database with updated IP country ranges, GeoLite Free is a choice. Some commercial databases provide location even into cities. After this, you can use the country code to get their corresponding flag.

To get WHOIS information there are several PHP classes that perform this function.

User agent and Referral URL is easy obtainable through $_SERVER environment variable. Deviating server load to client processing using Javascript to perform this tasks -like in your code- is always better.
Last edited by Tekmaven; Jul 21st, 2008 at 8:29 pm. Reason: Weird char in post
Reply With Quote Quick reply to this message  
Reply

This thread has been marked solved.
Perhaps start a new thread instead?
Message:



Other Threads in the PHP Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC