1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

GEO IP Redirect Script

Discussion in 'General Programming Chat' started by hunar, Feb 23, 2011.

  1. hunar

    hunar Regular Member

    Joined:
    Jan 1, 2009
    Messages:
    479
    Likes Received:
    178
    Location:
    Minnesota
    Hi, I'm just wondering if anyone would be able to create a GEO IP redirect Script. I need something like if user Clicks to buy product and they are from Us, CA, NZ, UK They will go to offer A. All others will go to Offer B.

    I'm looking for something very simple Where I don't have to create pages for each country code cause putting that on 200+ sites would literally take months.

    I'd be willing to pay as well. Just throw me a PM or Just reply in thread. :)
     
  2. nesterdwarf

    nesterdwarf Regular Member

    Joined:
    May 30, 2008
    Messages:
    276
    Likes Received:
    539
    Location:
    State of Misery...er, Missouri...
    Not to toot my own thread or anything, but GEOIP right here -

    Code:
    http://www.blackhatworld.com/blackhat-seo/black-hat-seo/268255-cpa-redirector-2-1-modded-geoip-variable-passing-url-rotation.html
    Which I cobbled together from another post here somewhere...do a little digging and you'll find it if the above doesn't work...

    HTH
    ND
     
  3. zelma143

    zelma143 Power Member

    Joined:
    Jun 25, 2010
    Messages:
    571
    Likes Received:
    37
    Occupation:
    PHP programmer,Bot maker,iMacro script maker
    yup.. that can help you out...

     
    • Thanks Thanks x 1
  4. CharlesManson

    CharlesManson Newbie

    Joined:
    Mar 9, 2011
    Messages:
    48
    Likes Received:
    1
    I have one custom made by a friend for CPA , PM me your IM if u still need this
     
  5. sweepypanda

    sweepypanda Newbie

    Joined:
    Jul 27, 2010
    Messages:
    20
    Likes Received:
    4
    Here's how I've done it in the past.

    PHP:
    $ip $_SERVER['REMOTE_ADDR'];
    $country file_get_contents("api.hostip.info/country.php?ip=$ip");
    Pretty simple. I would also make sure that the user isn't using a proxy. Check that like this:

    PHP:
    if (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) //IP is likely from Proxy
     
    • Thanks Thanks x 1