Changing links depending of the user location

Scipio00

Regular Member
Joined
Dec 4, 2010
Messages
445
Reaction score
69
I have an affiliate website in latin america and I wondered if I can change the affiliate links depending on the location of the User.

In the US this problem doesn't happen very often: You recommend a mobile phone and give an amazon affiliate link. Now the user gets redirected to amazon.com or amazon.co.uk or amazon.com.au depending on his location.

Unfortunately the market in latin america is way more fragmented. So if you recommend a mobile phone, you need an mexican aff link, an argentinian, a spanish one, a colombian one,...

If now the website checks the user location and changes the link accordingly we could solve this problem. Is that possible? If so, is a script for that existing? If not, how much is it to code something like that?
 
If you're using Wordpress, you could use the plugin "Visitor Country" to change your link depending on the location of you visitor. Here's a quick example I've made to show you what you could do with a simple shortcode :

pastebin /sB7Z9Qtd

(Errors occurred while I tried to submit it, got to put it in pastebin..)

After that, in your Wordpress post/page you just have to add something like :

[showMobilePhoneLink anchor="Click here to buy a mobile phone"]

And it will generate a good link depending of the visitor country with the anchor you specified. That way, you can use it on as many pages as you want and always get the good link & a custom anchor.

If you're not using Wordpress, you should try to find a script that use the MaxMind GEO Ip database.. It shouldn't be hard to find!

Good luck :)
 
On my side I am using a very old piece of software it is called click maximiser. It works for what I use it for. It redirects per country etc.
 
Back
Top