5$ for your location shown on a website - Can anyone please help?

Discussion in 'Programming' started by directfuture, May 8, 2009.

  1. #1
    Hi All,

    I have seen on some websites adverts that it can tell the location of the town I am from when viewing.

    How is this done?

    What programs or software is used?

    Can anyone help me as I would like to have this feature on my own website in the UK, anyone that can tell me how this is done I will reward with $5.

    Thanks
     
    directfuture, May 8, 2009 IP
  2. gary4gar

    gary4gar Peon

    Messages:
    496
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    0
    #2
    The Location is shown on base of Visitors IP address.

    if you want this feature in your own website, I would need few more details

    * Windows or Linux
    * Shared/VPS/Dedicated
    * do you have SSH access ?
     
    gary4gar, May 8, 2009 IP
  3. kblessinggr

    kblessinggr Peon

    Messages:
    539
    Likes Received:
    13
    Best Answers:
    0
    Trophy Points:
    0
    #3
    You can use either Maxmind's Geocity lite database here which is free and a PHP api is available for it: http://www.maxmind.com/app/geolitecity

    or you can use something even simpler with GeoPlugin to pull back an array of the user's info http://www.geoplugin.com/webservices/php

    Both of which will allow you to grab the visitor's estimated sity, just one has the data on your server, where as the other one the data is called from a url.
     
    kblessinggr, May 8, 2009 IP
  4. darpp33

    darpp33 Active Member

    Messages:
    59
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    91
    #4
    My suggestion
    Try FEEDJIT'S online showing tool. For more info do google search 'feedjit'
    To see itz sample check my signature
    I have used it with my blog!
     
    darpp33, May 8, 2009 IP
  5. mcliviu

    mcliviu Peon

    Messages:
    33
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    for geolocation just use the maxmind, it's the best!
     
    mcliviu, May 9, 2009 IP
  6. jerrywijaya

    jerrywijaya Banned

    Messages:
    20
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #6
    you can use php script called "ip to city" or use this script for javascript

    <script type="text/javascript">
    function getLocation(){
    	script = document.createElement('script')
    	script.src = 'http://www.nitinh.com/ip_query.php?callback=initialize'
    	document.body.appendChild(script)
    }
    
    function initialize(obj){
    	document.getElementById('spanLocation').innerHTML = obj['City'] + ", " + obj['RegionName'] + ", " + obj['CountryName'];
    }
    getLocation();
    </script>
     
    Your current location is: <span id='spanLocation'></span>
    PHP:
     
    jerrywijaya, May 9, 2009 IP
  7. monster64

    monster64 Peon

    Messages:
    26
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #7
    I recommend maxmind as well. Keep in mind though that you can never be certain of anything other than the country though.
     
    monster64, May 11, 2009 IP
  8. elenana

    elenana Guest

    Messages:
    34
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #8
    why don't u try the real-time visitor api from IPLocationTools.com? I woukld prefer this one than FeedJit
     
    elenana, Jul 24, 2009 IP
  9. yodayoz

    yodayoz Peon

    Messages:
    111
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #9
    ewebcounter.com offers this service for free and also gives professional reports
     
    yodayoz, Aug 5, 2009 IP